Capture Order

This endpoint is for fully or partially capture an authorised order. (deferred payment request.)

Resource URL

POST http://api.qa.optty.com/orders/{ORDER-ID}/capture

For live environment, please update the endpoint to https://api.optty.com

Path Parameters

Name
Type
Description

ORDER-ID*

string

The ORDER-ID provided in the original createOrder request is called 'orderReference' in createOrder.

Headers

Key
Value

Content-Type

application/json

Authorization

Bearer {GENERATED_ACCESS_TOKEN}

Parameters

Request Parameters

Field
Type
Description
Required

captureReference

string

The order capture reference, it needs to be unique per capture order request.

Yes

description

string

The description or reason for the capturing.

No

amount

numeric

amount to be captured

Yes

Response Parameters

Field
Type
Description

captureReference

string

The reference passed for the capturing request

captureId

string

The reference submitted upon requesting for capture.

capturedAmount

numeric

The amount processed for the capturing operation

Sample Request/Response

{
    "captureReference": "LatEHAuPtpN2HSrTMK-1",
    "description": "Please capture this order",
    "amount": 100
}
{
    "captureReference": "LatEHAuPtpN2HSrTMK-1",
    "capturedAmount": 100,
    "captureId": "LatEHAuPtpN2HSrTMK-1"
}

Last updated