# Query Status With Your Reference

## Get Transaction Status

<mark style="color:blue;">`GET`</mark> `https://a1pay.net/api/query/statuswithmyreference`

Get transaction status using your unique transaction reference

#### Query Parameters

| Name           | Type   | Description                                      |
| -------------- | ------ | ------------------------------------------------ |
| transactionRef | string | Your unique transaction reference                |
| merchantId     | string | Your Merchant ID provided to you at registration |

#### Headers

| Name | Type   | Description                                                      |
| ---- | ------ | ---------------------------------------------------------------- |
| Hash | string | SHA256 .of Amount in two decimal places + MerchantId + SecretKey |

{% tabs %}
{% tab title="200 JSON of status and data. data will carry transaction response object if call is successful, if not, it will carry a string representation of the error message. Even if status is success, always look out for the IsSuccessful property of the data object which must be true to show that the transaction is fully successful." %}

```javascript
{
    "status": "success",
    "data": 
    {
      "AmountPaid": "100000.00",
      "FriendlyMessage": "Transaction completed successfully",
      "FurtherExplanation": null,
      "IsSuccessful": true,
      "PayerEmail": "email@a1pay.net",
      "PayerName": "SOLOMON GRUNDY",
      "PaymentReference_Local": "A1PAYREFERENCE",
      "PaymentReference_Switch": "SWITCHREFERENCE",
      "ResponseCode": "00",
      "ResponseDescription": "Approved By Financial Institution",
      "TransactionDate": "02/06/2018",
      "TransactionType": "School Fees"
    }
}
```

{% endtab %}
{% endtabs %}

{% hint style="warning" %}
Always look out for the **IsSuccessful** property of the data object in the response. A status=success alone is not enough to determine that your transaction is successful
{% endhint %}

{% hint style="info" %}
Its always a good practice to log all responses from A1Pay for future reference.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://blended.gitbook.io/a1pay/accept-payment-using-a1pay/query-status-with-your-reference.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
