> For the complete documentation index, see [llms.txt](https://mekacash-1.gitbook.io/mekacash-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mekacash-1.gitbook.io/mekacash-api/verify-transaction.md).

# Verify Transaction

## Get Transaction Details

<mark style="color:green;">`POST`</mark> <https://mekacash.co.uk/api/charge/validation>

**Headers**

| Name          | Value                 |
| ------------- | --------------------- |
| Content-Type  | `application/json`    |
| Authorization | `Bearer <SECRET KEY>` |

**Body**

| Name         | Type   | Required | Description           |
| ------------ | ------ | -------- | --------------------- |
| reference \* | string | true     | transaction reference |

**Response**

{% tabs %}
{% tab title="200 : OK" %}

```json
{
  "data" : {
    "trxDetails" : {
        "status" : "approved",
        "message" : "Transaction is completed",
        "trxRef" : "bac3juaiaa",
        "amount" : "10.00",
        "currency" : "USD",
        "transDate" : "2023-11-19 21:10:22"
    },
    "custDetails" : {
        "fullName" : "Kay Nguyen",
        "email" : "kaynguyen@gmail.com",
        "phone" : "1234567890",
    },
    "cardDetails" : {
        "cardType" : "VISA",
        "cardNumber" : "4567******346789",
        "expiryDate" : "01/24"
    }
  }    
  "message": "success",
  "status": "success"
 }
```

{% endtab %}

{% tab title="400  : Bad Request" %}

```json
{
    "message":"Bad Request",
    "status":"failed"
}
```

{% endtab %}

{% tab title="401 : Unauthorized" %}

```json
{
    "message":"Invalid Token",
    "status":"failed"
}
```

{% endtab %}

{% tab title="404 : Not Found" %}

```json
{
    "message":"Transaction not found",
    "status":"failed"
}
```

{% endtab %}
{% endtabs %}
