# Get Payment Status v2.0Beta
The Get Payment Status endpoint retrieves the status for a previously submitted payment. A payment status record will be returned that provides the current status of the payment.
This endpoint can be polled periodically to fetch the current status. Once a payment is submitted to the payment processor, we can expect to receive multiple status updates for the payment. These updates update the payment data in our systems and are made available to you via this endpoint.
Depending on the payment scenario and may other factors, the payment flow will vary from payment to payment. For this reason, do not build logic that expects the status of a payment to always follow a specific order. Furthermore, a status may appear more than once - usually as a result of retry logic being invoked as a result of an unexpected error.
You can expect one of the following status values in the status
property of the response:
- Pending
- Processing
- Sent
- RequestReceived
- RedirectRequired
- Authorised
- Settled
- Failed
- CancelRequested
- Cancelled
# Request
# Authorization
An OAuth 2.0 Bearer token with the Payment.Read
scope is required. For more information, see Authentication.
# Path Parameters
A list of the supported path parameters is described below.
Name | Required | Type | Description |
---|---|---|---|
paymentId | true | guid | The payment identifier for the payment to fetch the status for. This value is returned when a payment is created. |
# Response
# Response Body
The endpoint returns our ApiResponse envelope. The data
property of the response will contain a PaymentStatus resource.
# Response Headers
# Sample
{
"message": "The operation succeeded!",
"notifications": [],
"data": {
"paymentId": "38ecb39d-ea98-443f-94d3-557404881d37",
"paymentCode": "81D37",
"transactionId": "20220211-0013-0000-0382",
"paymentMethod": "Card",
"paymentScenario": "Payment",
"currency": "ZAR",
"amount": 8800,
"actionUrl": "https://auth.payments.co.za/?id=2c5b9188-7d59-4c51-a486-24202821bfbc",
"status": "Authorised",
"statusReason": "Payment status updated to Authorised via reply message from the payment provider.",
"createdOn": "2022-02-11T04:51:50.5803212+00:00",
"processedOn": "2022-02-11T04:53:04.7469416+00:00",
"history": [
{
"status": "Pending",
"statusReason": "Payment created.",
"processedOn": "2022-02-11T04:51:50.4787277+00:00"
},
{
"status": "Processing",
"statusReason": "Started processing payment.",
"processedOn": "2022-02-11T04:51:51.0607526+00:00"
},
{
"status": "Sent",
"statusReason": "The payment was sent to the payment provider.",
"processedOn": "2022-02-11T04:51:52.3483174+00:00"
},
{
"status": "RedirectRequired",
"statusReason": "Payment status updated to RedirectRequired via reply message from the payment provider.",
"processedOn": "2022-02-11T04:51:59.827369+00:00"
},
{
"status": "Authorised",
"statusReason": "Payment status updated to Authorised via reply message from the payment provider.",
"processedOn": "2022-02-11T04:53:04.7469416+00:00"
}
]
}
}
# Errors
The standard error responses apply.