POST /payments
This operation will initiate a new payment for a user and the response will include a unique PaymentID to track the status of the transaction.
Request
Initiating a payment is performed by posting to /payments with the following body:
amount
Yes
The amount to request from the user in cents.
currencyCode
Yes
The payment currency to request from the user, e.g. DZAR
accountId
Yes
The unique ID of the merchant’s account to which to transfer the user’s payment to (if successful).
See Accounts for obtaining the correct accountId
.
reference
Yes
A unique reference generated and supplied by your system. This reference will be displayed to the user should they have any queries for the payment.
returnUrl
No
The URL to redirect the user to once payment has been completed.
An id
parameter will be appended to the returnUrl
which can be used by the Merchant’s system to query the status of the Payment.
countryCode
Yes
The country code of the user who is requesting the payment. This is the Alpha-2 country code as defined by https://www.iban.com/country-codes
Response
If successful, the operation will return a payment initiation response:
id
string($guid)
The unique Payment ID generated by 6DOT50 to be used in subsequent user redirects and method calls.
reference
string
Same value from Request.
amount
string
Same value from Request.
accountId
string($guid)
Same value from Request.
currencyCode
string
Same value from Request.
errorCode
int
Error code for the transaction if it failed to create. See Payment Error Codes for more information
createdAt
string($date-time)
Time in UTC when the payment was created.
Last updated