#tomasfejfar
1 messages · Page 1 of 1 (latest)
Hi there!
Can you share the ID (req_xxx) of the failing API request?
https://support.stripe.com/questions/finding-the-id-for-an-api-request
req_VURrdyPaNGvXWA
$paymentIntentId = $invoice
->payment_intent;
$paymentIntent = $stripeClient->paymentIntents->retrieve($paymentIntentId);
$stripeClient->paymentIntents->update($paymentIntent->id, ['setup_future_usage' => 'on_session']);
thanks for sharing let me check
Does the restricted key you are using ends with ene4Fi?
According to you code, you are trying to update a PaymentIntent, but that restricted key doesn't have payment_intent write permission, it has only read permission
Hmmm, let me check! (the ending is correct)
You were right! Now it passes. The error message is very misleading though. Also before it said I need to have checkout session write... so I assumed that the privileges are correct.
Thanks for the help, it now passes. ❤️
Welcome!