## PaymentMethod event Stripe.js automatically creates a [PaymentMethod](/api/payment_methods.md) after the customer is done interacting with the browser’s payment interface. To access the created `PaymentMethod`, listen for this event. **Syntax:** `paymentRequest.on(...)` - `event` (string) **required** The name of the event. In this case, `paymentmethod`. - `handler` (function) **required** A callback function that will be called with a [PaymentResponse](/js/appendix/payment_response.md) object when the event is fired. The `PaymentResponse` object will contain a `paymentMethod` field. ### Handle 'paymentmethod' event ```js paymentRequest.on('paymentmethod', function(event) { // event.paymentMethod is available }); ``` ```es_next paymentRequest.on('paymentmethod', ({paymentMethod}) => { // paymentMethod is available }); ```