Payments - Confirm[confirm the payment which in requires_payment_method]
POST {{baseUrl}}/payments/:id/confirm
This API is to confirm the payment request and foward payment to the payment processor. This API provides more granular control upon when the API is forwarded to the payment processor. Alternatively you can confirm the payment within the Payments-Create API
Request Body
{"return_url"=>"http://example.com/payments", "payment_method"=>"card", "payment_method_data"=>{"card"=>{"card_number"=>"4242424242424242", "card_exp_month"=>"10", "card_exp_year"=>"35", "card_holder_name"=>"John Doe", "card_cvc"=>"123"}}, "shipping"=>{"address"=>{"city"=>"Bangalore", "country"=>"IN", "line1"=>"Juspay router", "line2"=>"Koramangala", "line3"=>"Stallion", "state"=>"Karnataka", "zip"=>"560095", "first_name"=>"John", "last_name"=>"Doe"}}, "billing"=>{"address"=>{"city"=>"Bangalore", "country"=>"IN", "line1"=>"Juspay router", "line2"=>"Koramangala", "line3"=>"Stallion", "state"=>"Karnataka", "zip"=>"560095", "first_name"=>"John", "last_name"=>"Doe"}}}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |