# GET /payments/{id}

Use this operation to query the status of a particular payment. It is typically used when the user is redirected back to your `redirectUrl`, so that you can decide how to handle the payment status during your check out process.

See [Payment Status Codes](../../redemptions-api/payment-codes#status-codes) to determine the status of the payment.

### Request

Ensure the bearer token is included in the Header of the GET operation:

<table><thead><tr><th width="197.33333333333331">Header</th><th width="120">Mandatory</th><th>Description</th></tr></thead><tbody><tr><td><code>Authorization</code></td><td>Yes</td><td>Bearer token from <a href="../redemptions-api/authentication/post-authentication-gettoken">/authentication/getToken</a></td></tr></tbody></table>

<table><thead><tr><th width="199.33333333333331">Parameter</th><th width="118">Mandatory</th><th>Description</th></tr></thead><tbody><tr><td><code>id</code></td><td>Yes</td><td>The 6DOT50 unique Payment ID (<code>paymentId</code>) to query.</td></tr></tbody></table>

### Response

If successful, the operation will return with a standard Payment model:

```
{
  "id": "string($guid)",
  "reference": "string",
  "amount": "string",
  "accountId": "string($guid)",
  "currencyCode": "string",
  "statusCode": int,
  "statusMessage": "string",
  "errorCode": int,
  "errorMessage": "string",
  "createdAt": "string($date-time)",
  "completedAt": " string($date-time)",
  "countryCode": "string",
  "returnUrl": "string"
}
```

<table><thead><tr><th width="192.33333333333331">Field</th><th width="183">Response Type</th><th>Description</th></tr></thead><tbody><tr><td><code>id</code></td><td>string($guid)</td><td>The unique Payment ID generated by 6DOT50 to be used in subsequent user redirects and method calls.</td></tr><tr><td><code>reference</code></td><td>string</td><td>Same value from Request.</td></tr><tr><td><code>amount</code></td><td>string</td><td>Same value from Request.</td></tr><tr><td><code>accountId</code></td><td>string($guid)</td><td>Same value from Request.</td></tr><tr><td><code>currencyCode</code></td><td>string</td><td>Same value from Request.</td></tr><tr><td><code>statusCode</code></td><td>int</td><td>Status code for the transaction. See <a href="../../redemptions-api/payment-codes#status-codes">Payment Status Codes</a> for more information.</td></tr><tr><td><code>statusMessage</code></td><td>string</td><td>A display message for the status code. See <a href="../../redemptions-api/payment-codes#status-codes">Payment Status Codes</a> for messages.</td></tr><tr><td><code>errorCode</code></td><td>int</td><td>Error code for the transaction if it failed to create. See <a href="../../redemptions-api/payment-codes#error-codes">Payment Error Codes</a> for more information</td></tr><tr><td><code>errorMessage</code></td><td>string</td><td>A display message for the error code. See <a href="../../redemptions-api/payment-codes#error-codes">Payment Error Codes</a> for messages.</td></tr><tr><td><code>createdAt</code></td><td>string($date-time)</td><td>Time in UTC when the payment was created.</td></tr><tr><td><code>completedAt</code></td><td>string($date-time)</td><td>Time in UTC when the payment was completed (final state).</td></tr></tbody></table>

{% code title="Sample Response" %}
```
{
  "id": "009c3481-a65c-4afa-a950-1f5bce710493",
  "reference": "ref12345678",
  "amount": "10000",
  "accountId": "00000000-0000-0000-0000-00000000000",
  "currencyCode": "DZAR",
  "statusCode": 0,
  "statusMessage": "Payment is in progress",
  "errorCode": 0,
  "createdAt": "2022-09-26T11:40:47.33",
  "countryCode": "ZA",
  "returnUrl": "https://redirect.merchant.com"
}

```
{% endcode %}
