Capture Method
Description
The Capture method requests the settlement of the funds reserved through an Authorize transaction.
Action
Style
Document
Input (Literal)
The input of this method is the document element CaptureRequest having the structure defined by the following table.
ELEMENT |
TYPE |
SIZE(MAX) |
DESCRIPTION |
MessageHeader |
|
|
|
MessageDateTime |
datetime |
The message timestamp. |
|
MessageID |
string |
50 |
A unique identifier to identify the message. |
Channel |
string |
50 |
An identifier to identify the source of the message. |
CaptureRequest |
|
|
|
MerchantID |
string |
50 |
A unique identifier to identify the merchant. Also known as Merchant GUID. |
TransactionID |
string |
50 |
A unique identifier provided by the merchant on the API call to identify the transaction |
PreviousTransactionID |
string |
50 |
A unique identifier to identify a preceding transaction (Authorize). |
TransactionDateTime |
datetime |
The transaction timestamp. |
|
SaleReconID |
string |
100 |
A unique identifier for reconciliation purposes. |
ReconID |
string |
50 |
A unique identifier for reconciliation purposes. |
Amount |
long |
The authorization amount in the lowest monetary unit. |
|
CurrencyCode |
string |
3 |
The currency code according to the ISO 4217 standard. |
OrderNumber |
string |
50 |
The transaction order or reference number. Only 0-9, A-Z or a-z allowed. Spaces are not allowed. |
PaymentService |
The target payment service. |
||
MerchantCategoryCode |
string |
4 |
This parameter is optional. It is used when a merchant wishes to pass a unique MCC (MerchantCategoryCode) eg: 5399 |
Output (Literal)
The output of this method is the document element CaptureResponse having the structure defined by the following table.
ELEMENT |
TYPE |
SIZE(MAX) |
DESCRIPTION |
MessageHeader |
|
|
|
MessageDateTime |
datetime |
The message timestamp. |
|
MessageID |
string |
50 |
A unique identifier to identify the message. |
Channel |
string |
50 |
An identifier to identify the source of the message. |
CaptureResponse |
|
|
|
TransactionID |
string |
50 |
A unique identifier to identify the transaction. |
TransactionDateTime |
datetime |
The transaction timestamp. |
|
ReconID |
string |
50 |
A unique identifier for reconciliation purposes. |
AuthCode |
string |
50 |
The result code definition. |
TransactionStatus |
TransactionStatusType |
The transaction status (Success and Failure) |
|
ResponseDetail |
The transaction result code. |
Sample Message
Request
Body
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:="http://www.ecentricswitch.co.za/paymentgateway/v1">
<soapenv:Header>
<MessageHeader>
</MessageHeader>
</soapenv:Header>
<soapenv:Body>
<CaptureRequest>
<MerchantID>8B67BF88-BB8D-4EB5-ADFC-0F5C97C7ED67</MerchantID>
<MerchantUserID>978e566b-d62a-42c0-9843-381b3588f333</MerchantUserID>
<TransactionID>f52a357b-62d4-41d3-a45a-e60099c85ba3</TransactionID>
<PreviousTransactionID>9ee8b2be-4d86-494c-8e5f-b2182ce49d71</PreviousTransactionID>
<OrderNumber>MR64503998</OrderNumber>
<CurrencyCode>ZAR</CurrencyCode>
<Amount>50</Amount>
<PaymentService>CardNotPresent</PaymentService>
</CaptureRequest>
</soapenv:Body>
</soapenv:Envelope>
Response
Body
<s:Envelope
xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header>
<h:MessageHeader
xmlns:h="http://www.ecentricswitch.co.za/paymentgateway/v1"
xmlns="http://www.ecentricswitch.co.za/paymentgateway/v1"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<MessageDateTime>2024-11-14T12:14:59.747</MessageDateTime>
<MessageID>4398946F-E431-400B-B290-157B8D4B74FD</MessageID>
<Channel xsi:nil="true"/>
</h:MessageHeader>
</s:Header>
<s:Body
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CaptureResponse xmlns="http://www.ecentricswitch.co.za/paymentgateway/v1">
<TransactionID>f52a357b-62d4-41d3-a45a-e60099c85ba3</TransactionID>
<TransactionDateTime>2024-11-14T12:14:59.53</TransactionDateTime>
<SaleReconID xsi:nil="true"/>
<ReconID/>
<AuthCode>868536</AuthCode>
<TransactionStatus>Success</TransactionStatus>
<ResponseDetail>
<Source>Acquirer</Source>
<Code>00</Code>
<Description>Approved or completed successfully</Description>
<ClientMessage>Approved.</ClientMessage>
</ResponseDetail>
</CaptureResponse>
</s:Body>
</s:Envelope>