#Uniext - Subscription Flows
1 messages · Page 1 of 1 (latest)
Hi. Yeah I can help with this. So, one is automatically created for this. You can access it via this parameter: https://stripe.com/docs/api/subscriptions/object#subscription_object-pending_setup_intent
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Ah, so it seems I first create a subscription with payment_behavior=default_incomplete, whilst also providing a payment method id to default_payment_method. Then the pending_setup_intent will be non null and I handle it if it has problems?
Yeah
Sorry, just to clarify, what do you mean by "handle it if it has problems"? The creation of the subscription?
By that, I mean if the pending_setup_intent has any authentication or authorization errors. Like if its status becomes requires_action or requires_payment_method.
Okay thank you. So if you had an authentication error, that being the pending_setup_intent's status is requires_action, how would you handle it on a platform that is not web bases or has any available stripe sdks. More specifically this docs (https://stripe.com/docs/billing/subscriptions/overview#authentication-failures) specifies that we should call confirmCardSetup on your frontend, but this appears to be a js library. Is there any restful api we can call, this would allow me to confirm from another language, like rust.
You can confirm a setup intent like so: https://stripe.com/docs/api/setup_intents/confirm
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
If the status is requires_action, then the suggested next steps will be within next_action
I understand that I can call this to confirm a setup intent, but, correct me if im wrong, this seems to be only possible from the backend. Is there any way to call this from the front end, like what is done with confirmCardSetup , but for non js or sdk platforms?
Sorry what platform are you interested in confirming this on? Is this for a mobile environment?
Just confused because you say you want to do this from the front-end on a non-js platform
Oh okay. This platform isn't mobile. The platform will be a linux, where the front-end is programmed in rust. I was hopeing there was some sort of RESTful api I could just make requests to.
You can make the API call to confirm a setup intent from the front-end and use your public key. However, if you go this route of implementing your own front-end in Rust for a desktop application, you are going to have strict PCI compliance standards you'll have to abide by. That's the advantage of using Stripe Elements with the JS front-end. Stripe takes care of all of those concerns. https://stripe.com/en-gb-sg/guides/pci-compliance
Does this strict compliance only matter because we are exposing confirmation via the front end?
PCI compliance applies to all online payments. If you need some more background as to what it is, in addition to our article above, you can go here: https://www.pcisecuritystandards.org/
If you are a merchant of any size accepting credit cards, you must be in compliance with PCI Security Council standards. This site provides: credit card data security standards documents, PCIcompliant software and hardware, qualified security assessors, technical support, merchant guides and more.
But yes, it is because you are taking in sensitive card data in a front-end and could be exposing those details
The issue is that you are collecting raw credit card info in your form rather than through Stripe's PCI compliant method with Elements