#Shankar
1 messages · Page 1 of 1 (latest)
hi! not sure exactly what you mean.
Capturing an authorised payment can never fail.
if you want to capture less than you authorised, you would just pass the exact amount you do want to capture. https://stripe.com/docs/api/payment_intents/capture#capture_payment_intent-amount_to_capture
we are unable to capture the amount so in that case after 24 hrs we want to settle all the authorized payments means all the payments which are in authorized state but not captured should be captured with the whole authorized amount.
cool, then you just call the API job in a batch job for example.
for example maybe call the List PaymentIntent API, filtered to the last 24 hours, look for any returned objects that have status:requires_capture, and call the capture API on those. Not sure if that's the kind of solution you're looking for.
I still don't know what you mean by "we are unable to capture the amount " exactly, was there some specific error you ran into?
can i get the APIs to achieve this ?
the API to get list of require_capture status objects and also the API to capture all require_capture objects
https://stripe.com/docs/api/payment_intents/list is how you list PaymentIntents, and then you write code in your application to inspect each returned object and check its status, and then https://stripe.com/docs/api/payment_intents/capture is how you capture a specific PaymentIntent.