#trueinviso
1 messages · Page 1 of 1 (latest)
Is the goal essentially to simulate a renewal failure?
yes
Gotcha. You can use test clocks to advance time: https://stripe.com/docs/billing/testing/test-clocks. And then use a test card that fails payment: https://stripe.com/docs/testing#declined-payments
Which card can I use that fails payment? I tried adding some to the account and it wouldn't let me
I tried the insufficient funds one, and I couldn't add it
Oh I think I found it
4000000000000341
declined after attaching it says
Yep that's the one you'll want to use
I don't see anything in the docs about canceling a past due subscription, will that api call succeed if it's a past due subscription?
Yeah the regular cancel subscription endpoint will work: https://stripe.com/docs/api/subscriptions/cancel
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
You can also alter your settings to cancel subscriptions automatically after a certain number of retries, etc: https://dashboard.stripe.com/settings/billing/automatic
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.