#.suryamani
1 messages · Page 1 of 1 (latest)
👋 how may I help?
I need to test stripe payment in local how will i do that?
I'm using webhook event, I need to check that events
what exactly?
If i try to subscribe enter card details and click subscribe but it need to fail how will i test it?
the event is invoice.payment.failed
actually if you're just testing the webhook events
you can use the Stripe CLI to trigger certain events
Can you explain breifly?
for the available list of triggers you can look at https://github.com/stripe/stripe-cli/tree/master/pkg/fixtures/triggers
invoice.payment_failed is available
How to hit the invoice.payment.failed event in local by Subscribe
first you need to install the Stripe CLI
launch the stripe listen command https://stripe.com/docs/cli/listen
then trigger the event with stripe trigger
I'm install it by using cmd
Is any possible way to my question, I subscribe by entering card details and click subscribe that time payment need to fail and trigger the invoice.payment.failed
I just described how in my last messages
you just need to specify the forward-to param https://stripe.com/docs/cli/listen#listen-forward-to
to forward the events to your local-hosted app
and run stripe trigger invoice.payment_failed
I forward it my api Webhook Post method and give breakpoint to check it
I need to run stripe trigger invoice.payment_failed in my command prompt, I'm i right?
yes correct