#vell2x_docs
1 messages ¡ Page 1 of 1 (latest)
đ Welcome to your new thread!
â˛ď¸ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
âąď¸ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
đ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1328886954200268811
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hello!
Can payment intents create subscriptions?
No. Subscriptions create Invoices, and Invoices create Payment Intents. You can't go the other way, from a Payment Intent up to an Invoice, and then up to a Subscription.
Can I replace payment intents with checkout sessions?
Probably not, but I'm not sure I fully understand this question. Can you provide more details?
Should the subscription be handled by my server using payment intent?
Also not sure I fully understand this question.
It would probably be best if you tell me what you want to build, then I can provide recommendations and guidance for building it.
So the payment flow goes as follows. User selects a package, and subscription type(one time, weekly, monthly). From there I want to create the intent(it sounds like I should be creating a invoice). Use pays and subscription starts if applicable.
To clarify, you want the customer to pay using the Payment Element, not Checkout?
I would prefer Checkout, but my understanding is PaymentSheet only uses payment intent
Wait, sorry, PaymentSheet? I think I need more context. Are you building something in a mobile app?
PaymentSheet is a mobile UI compoent we provide for mobile apps, it's not something you can use on the web.
Sorry, yes I am building an Android app via Kotlin.
Ah, okay, so you're in fact not using Payment Element at all, since this isn't happening on a web page?
V1 of the app the way I handled payments by sending users to a webpage(nodejs) where they would pay and be sent back to the app. Now I want to allow users to pay within the app.
Gotcha. So the high level approach would be to create a Subscription on your server, which will then create an Invoice, and the Invoice will create a Payment Intent, and then you can pass that Payment Intent's client secret to the Payment Sheet to pay for the Payment Intent, which will in turn pay for the Invoice, and thus the Subscription.