#usamarashad
1 messages · Page 1 of 1 (latest)
Hello. What's your question?
I need some help to understand how to create a subscription that terminates after 4 months
I started writing some code.
And this is what i did
I first collect the payment intent by using the React front end Element
I get a successfull payment showing on my dashboard
where do i go from here ?
What is the relation between payment intent and payment method?
How do I retreive this payment method for a given customer ?
If you want a subscription you shouldn't use payment intents at all
Recommend you read this guide: https://stripe.com/docs/billing/subscriptions/build-subscriptions?ui=elements
the website seemd to suggest payment intents if payments were to be used for a future time
thats what led me to use the payment API
Payment Intents are for 1-time payments
If you want a subscription, use subscriptions
When you get to step 4 in above guide, you can pass cancel_at to set the date 4 months after creation: https://stripe.com/docs/api/subscriptions/create#create_subscription-cancel_at
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Noted.
The webpage you recommended shows how to create price model on the dashboard. Can this be created via code using the Prices API?
Ok. Are you available for support 24x7?
And you're not a bot right ?
Correct
We're real people here
And this isn't stripe support to be clear
This is the developer discord. We just help with dev questions
I got it. And I just had to ask to be sure
can we find sellix shops?