Skip to content

Testing payments

After creating a payment intent, confirm it with the Stripe CLI:

Terminal window
stripe payment_intents confirm <pi_...> \
--payment-method pm_card_visa \
--return-url "https://example.com/done"

With stripe listen running, the resulting webhook updates the local payment.

Payment method Result
pm_card_visa Succeeds
pm_card_chargeDeclined Declines
Terminal window
npm test # unit tests
npm run build # production build