> For the complete documentation index, see [llms.txt](https://developers.klasha.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.klasha.com/transfers/payout/ghs-payout-new-encryption.md).

# GHS Payout (new encryption)

### Summary

These APIs are used to initiate a GHS payout

{% hint style="info" %}
Before you begin!

* Find your keys on the Klasha Dashboard → Settings → Generate API Keys ([here](https://dashboard.klasha.com/settings/keys))

<img src="/files/LFFicElNA6dWGpxBEdo1" alt="" data-size="original">
{% endhint %}

## Integration steps

{% content-ref url="/pages/p15ikIRu4qZuG2xRX2op" %}
[Authentication](/overview/authentication.md)
{% endcontent-ref %}

#### [Encryption algorithm here](/accepting-payments/payments-api.md#encryption-algorithm)

### **Get Bank Lists**

## Make a GET call to the Bank List API&#x20;

<mark style="color:blue;">`GET`</mark> `{{env_url}}/wallet/merchant/bank/transfer/request/banks/GHS`

#### Headers

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

<pre class="language-json"><code class="lang-json">{
    "message": "success",
    "error": null,
    "data": [
<strong>        {
</strong>            "id": 752.0,
            "code": "10550214",
            "name": "The Hongkong and Shanghai Banking Corporation Limited"
        },
        {
            "id": 753.0,
            "code": "11088200",
            "name": "Giro Elszamolasforgalmi Zrt."
        },
        {
            "id": 754.0,
            "code": "11276282",
            "name": "First National Bank Ghana Limited"
        },
        {
            "id": 755.0,
            "code": "11299458",
            "name": "OMNIBANK GHANA LIMITED"
        }
    ]
}
</code></pre>

{% endtab %}
{% endtabs %}

### **Get Bank Codes**

### Make a GET call to the Branch Code API&#x20;

<mark style="color:blue;">`GET`</mark> `{{env_url}}/wallet/merchant/bank/transfer/request/branch-code/{bankid}`

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

```json
{
    "message": "success",
    "error": null,
    "data": [
        {
            "id": 2391.0,
            "branch_code": "1812051EPC",
            "branch_name": "1st Natl Bank Ghana Ltd",
            "swift_code": null,
            "bic": null,
            "bank_id": 754.0
        }
    ]
}
```

{% endtab %}
{% endtabs %}

### Get Mobile Money Lists&#x20;

## Make a GET call to the Mobile Money List API&#x20;

<mark style="color:green;">`GET`</mark> `{{env_url}}/wallet/merchant/bank/transfer/request/banks/GHS?type=mobile-money`

#### Headers

#### Response Body

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

```json
{
    "message": "success",
    "error": null,
    "data": [
        {
            "code": "MTN",
            "name": "MTN Mobile Money"
        },
        {
            "code": "VODAFONE",
            "name": "Vodafone Mobile Money"
        },
        {
            "code": "AIRTELTIGO",
            "name": "Airtel-Tigo Mobile Money"
        }
    ]
}
```

{% endtab %}
{% endtabs %}

### **Merchant Bank Account Payout request**

## Make a POST call to the Merchant payout request API

<mark style="color:green;">`POST`</mark> `{{env_url}}/wallet/merchant/{businessId}/bank/transfer/v2/request`

You would need to pass, as a header the <mark style="color:red;">x-auth-token</mark>. This can be obtained from your merchant **dashboard → Settings → Generate API keys → Merchant public key**.

You would need to pass, as a header the <mark style="color:red;">x-auth-token</mark>. This can be obtained from your merchant **dashboard → Settings → Generate API keys → Merchant public key**.

#### Headers

| Key           | Value                    |
| ------------- | ------------------------ |
| Content-Type  | application/json         |
| x-auth-token  | Your merchant public key |
| Authorization | Bearer \<token here>     |

**Request body (encrypted):**

```json
{ 
  "message": "encrypted-request-body"
}
```

**Request body (plain)**

#### Request Body

<table><thead><tr><th width="264">Name</th><th width="160">Type</th><th>Description</th></tr></thead><tbody><tr><td>country<mark style="color:red;">*</mark></td><td>String</td><td>GH</td></tr><tr><td>bankCode<mark style="color:red;">*</mark></td><td>String</td><td>10550214</td></tr><tr><td>branchCode<mark style="color:red;">*</mark></td><td>String</td><td>1812062RXQ</td></tr><tr><td>amount<mark style="color:red;">*</mark></td><td></td><td>1000</td></tr><tr><td>accountName<mark style="color:red;">*</mark></td><td>String</td><td>John Jane Doe</td></tr><tr><td>requestId<mark style="color:red;">*</mark></td><td>String</td><td>kbtr-3857-011-133-166993253334816</td></tr><tr><td>description<mark style="color:red;">*</mark></td><td>String</td><td>Payout</td></tr><tr><td>currency<mark style="color:red;">*</mark></td><td>String</td><td>GHS</td></tr><tr><td>bankName<mark style="color:red;">*</mark></td><td>String</td><td>The Hongkong and Shanghai Banking Corporation Limited</td></tr><tr><td>accountNumber<mark style="color:red;">*</mark></td><td>String</td><td>10101010101</td></tr></tbody></table>

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

```json
{
    "id": 1205,
    "amount": 100.00,
    "payoutStatus": "PENDING",
    "requestId": "tranf-55b59c78-0093-4c6a-8370-5778c1bde9e3",
    "narration": "GIFT_AND_DONATION",
    "country": "GH",
    "fee": 15.00,
    "bankCode": "10550214",
    "bankName": "The Hongkong and Shanghai Banking Corporation Limited",
    "accountNumber": "10010101011",
    "accountName": "John Jane Doe"
}
```

{% endtab %}

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

```javascript
{
    "message": "A human readable error message",
    "error": "Bad Request",
    "data": null
}
```

{% endtab %}
{% endtabs %}

### **Merchant Bank Account Payout request**

## Make a POST call to the Merchant payout request API

<mark style="color:green;">`POST`</mark> `{{env_url}}/wallet/merchant/{businessId}/bank/transfer/v2/request`

#### Headers

| Key           | Value                    |
| ------------- | ------------------------ |
| Content-Type  | application/json         |
| x-auth-token  | Your merchant public key |
| Authorization | Bearer \<token here>     |

**Request body (encrypted):**

```json
{ 
  "message": "encrypted-request-body"
}
```

**Request body (plain)**

#### Request Body

<table><thead><tr><th width="264">Name</th><th width="160">Type</th><th>Description</th></tr></thead><tbody><tr><td>country<mark style="color:red;">*</mark></td><td>String</td><td>GH</td></tr><tr><td>serviceCode<mark style="color:red;">*</mark></td><td>String</td><td>MTN</td></tr><tr><td>amount<mark style="color:red;">*</mark></td><td></td><td>1000</td></tr><tr><td>accountName<mark style="color:red;">*</mark></td><td>String</td><td>John Jane Doe</td></tr><tr><td>requestId<mark style="color:red;">*</mark></td><td>String</td><td>kbtr-3857-011-133-166993253334816</td></tr><tr><td>description<mark style="color:red;">*</mark></td><td>String</td><td>Payout</td></tr><tr><td>currency<mark style="color:red;">*</mark></td><td>String</td><td>GHS</td></tr><tr><td>bankName<mark style="color:red;">*</mark></td><td>String</td><td>MTN Mobile Money</td></tr><tr><td>accountNumber<mark style="color:red;">*</mark></td><td>String</td><td>233540105690</td></tr></tbody></table>

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

```json
{
    "id": 1206,
    "amount": 100.00,
    "payoutStatus": "PENDING",
    "requestId": "tranf-7956670a-2912-4e74-a54d-ca89c89c7609",
    "narration": "MEDICAL_TREATMENT",
    "country": "GH",
    "fee": 2.50,
    "bankCode": "VODAFONE",
    "bankName": "Vodafone Mobile Money",
    "accountNumber": "233540105690",
    "accountName": "John Jane Doe"
}
```

{% endtab %}

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

```javascript
{
    "message": "A human readable error message",
    "error": "Bad Request",
    "data": null
}
```

{% endtab %}
{% endtabs %}

### **Query payout status**

Make a [call](/transfers/payout.md#polling-transfer-statuses) to fetch status of initiated payouts.
