#venkateshjsoft
1 messages · Page 1 of 1 (latest)
for the recurring payments, we need to collect subscription fee from the customer
after 15 days
I see here we set Mode = "setup"
than mode = "payment"
can we use this mode for all payment methods?
card, ideal, sepa-debit etc
All payment methods that support it, yes
okay thanks
let me check
Stripe.StripeException: Mode cannot be setup when using prices.
im getting this error
Sounds like you're trying to pass a price into Checkout Session that's in setup mode. Either change it to payment mode, or remove the Price
as per this document, on the step 3, it says charge your customer again
but in the step 1 and 2 we are not charging the customer
also in the checkout page, we are not showing how much money we are going to charge customer
That error only occurs when you're creating a Checkout Session in setup mode while trying to pass it a Price object ID or while passing line_item
I understand
im trying to find solution to address 2 problems
I have 2 types of payment (card, ideal, sepa, sofort)
I want to charge the customer first time and later during renewal
I was trying to use checkout option
with mode = payment
this works fine for all payment types, but I want to charge the customer again during renewal, I belive ideal, sofort wont support this
how can i solve this issue
If you're using Subscriptions with Stripe, you can't. They don't support subscription charges. If you just want to charge them again, you create a payment and pass in the Payment Method's ID
okay fine
When you need to charge your customer again, create a new PaymentIntent. Find the ID of the SEPA Direct Debit payment method by retrieving the SetupIntent and expanding the latest_attempt field where you will find the generated_sepa_debit ID inside of payment_method_details.
im not able to see the payment_method_details inside the setuppayment response
var options = new SetupIntentGetOptions
{
Expand = new List<string> { "latest_attempt" },
};
var service = new SetupIntentService();
service.Get("{{SETUP_INTENT_ID}}", options);
Hello! I'm taking over and catching up...
Can you give me the ID of the Setup Intent you're trying to get the latest_attempt from?
seti_1NdcDWDEdWHgNJdagK7RPWmh
the object is not availabel to access
looks like its a mistake in the document
there is no class payment_method_details under setupintent response
Looking...
You should be able to see info on the Setup Attempt object here: https://stripe.com/docs/api/setup_attempts/object#setup_attempt_object-payment_method_details-sepa_debit
Or, actually, it might be here in this specific case: https://stripe.com/docs/api/setup_attempts/object#setup_attempt_object-payment_method_details-ideal
Have you looked at those properties?
as per this document I can get the SEPA_DEBIT_PAYMENT_METHOD_ID from the setup intent
var options = new SetupIntentGetOptions
{
Expand = new List<string> { "latest_attempt" },
};
var service = new SetupIntentService();
service.Get("{{SETUP_INTENT_ID}}", options);
What do you do after that though?
var options = new SetupIntentGetOptions
{
Expand = new List<string> { "latest_attempt" },
};
var service = new SetupIntentService();
return service.Get(setupIntentId, options);
Right, then what?
this method returns setup intent, but in the response Im not able to find any property related to SEPA_DEBIT_PAYMENT_METHOD_ID
I need this to process the actual payment
I setup the payment first, now I need to charge the customer with the actual price
so I need sepa debit payment method id
I don't understand what you mean when you say you can't find the property; can you share the full object you're getting back?
Unfortunately I can't see GET request responses on my end. Can you log the entire object in your code and provide the output?
Yeah, it's right there where it's expected to be, pm_1NdcnlDEdWHgNJdaTRI1k3Lf under latest_attempt.payment_method_details.ideal.generated_sepa_debit.