#insert_username_here-mandate
1 messages · Page 1 of 1 (latest)
The Mandate object’s ID is accessible from the payment_method_details on the charge object of the PaymentIntent, which is part of the payment_intent.processing event sent after confirmation. Once you have the Mandate id, you can retrieve it via through the API [0] and you should be able to find the URL in the return object
i want to access it through API so I would have to fetch payment intent, then fetch charge and then get mandate url?
if you're using webhooks to listen to events, the payment_intent.succeeded and payment_intent.processing webhook will already contain the mandate id and you can use that to retrieve the mandate. You wouldn't need a separate API call to retrieve the PaymentIntent first.
If you're accessing it via the API, when retrieving the PaymentIntent object, it should already contain the payment_method_options so you don't need to fetch the charge again
I also need mandate url to show it to the client. Do I need to fetch mandate separately again through API to get mandate url?
The process is much more intuitive and simple when using setup intent as mandate url is returned.
there isn't another way as far as I can tell. You're going to need to fetch the mandate separately
Thanks