> For the complete documentation index, see [llms.txt](https://docs.udara360.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.udara360.io/udara360-docs-1/bills-payments/bill-payments/tsq.md).

# TSQ

The "TSQ" (Transaction Status Query) endpoint allows customers to check the status of a previous Vend transaction.

<mark style="color:yellow;">`POST`</mark> `/api/bills/v1/TSQ`

To query a transaction's status, you need to provide the `transactionReference` of the original Vend request.

**Headers**

| Name                                            | Value                |
| ----------------------------------------------- | -------------------- |
| Content-Type<mark style="color:red;">\*</mark>  | `application/json`   |
| Authorization<mark style="color:red;">\*</mark> | `Bearer`             |
| Request-Reference                               | `{unique_reference}` |

**Body**

<table><thead><tr><th>Name</th><th>Data Type (Length)</th><th data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td><code>transactionReference</code></td><td>string (50)</td><td>true</td><td>The paymentReference of the original Vend transaction being queried.</td></tr></tbody></table>

Here is an example request and response with a sample payload sent to the endpoint in Curl format.

<details>

<summary>Sample Request</summary>

```json
curl --location -g '{{baseurl}}/api/bills/v1/TSQ' \
--header 'Authorization: bearer {token}' \
--header 'request-reference: {unique_reference}' \
--header 'Content-Type: application/json' \
--data '{
  "transactionReference": "STmAZ2zXM42wXI5yzKA0jTXPb7NMVE"
}'
```

</details>

<details>

<summary>Response: <code>200</code></summary>

```json
{
  "data": {
    "tokenValue": null,
    "unitsType": "Kwh",
    "token": "53268833131286689562",
    "billerName": null,
    "paymentReference": "STmAZ2zXM42wXI5yzKA0jTXPb7NMVE",
    "transactionId": "231117000301_77",
    "vendStatus": "CONFIRMED",
    "narration": "Bill Purchase-IKEDC/IKEDC_PREPAID",
    "statusCode": null,
    "amount": 100000,
    "date": "2024-12-03T10:46:07.26",
    "tokenAmount": 0,
    "tokenUnits": 16.3,
    "tokenDaysLastVended": null,
    "packageName": "IKEDC_PREPAID",
    "paid": false,
    "kct1": null,
    "kct2": null,
    "walletBalance": 0,
    "convenienceFee": 0
  },
  "status": true,
  "message": "Request successful"
}
```

</details>
