Payments: Authorize & Capture
When you are making a server to server payment request, this API allows you to perform an Authorize & Capture in a single call.
Note:
This is a Client Authorized call.
Authorize & Capture a Payment Request
POST https://app.sign2pay.com/api/v2/payment/authorize/capture
Parameter | Required | Type | Description |
---|---|---|---|
client_id | yes | Number | The client id issued to your Sign2Pay Client Application. |
amount | yes | Integer | Amount of payment being requested in cents. |
ref_id | yes | String | Your unique id for your purchase. |
token | yes | String | The Access Token you just received. |
meta_data | no | Hash | Optional data attached to a payment. This is not shown to a customer. |
Request Headers & Body
Accept: */*
Accept-Encoding: gzip, deflate
Content-Type: application/json
Authorization: Basic YzUwOWZkNTkzNzQyYjZiMDhhZGY0ZjBiNDFhNDgwMWM6YTVjMWQyN2U0MGEzMGRkNjA2OTgyNTc4MWEyYWJlNGY=
Accept-Language: en-us
{
"amount": 500,
"client_id": "c509fd593742b6b08adf4f0b41a4801c",
"ref_id": "a742e5ba64c887e6314",
"token": "bb1cd6ce37d093eb2e8c32e7ec9847b3058112b92d3868371ae5426c463dad0d",
"meta_data": { "promo": "new_promo", "campaign": "wintersale" }
}
Response Body
{
"purchase_id": "55fac531e6db99858e000000"
}