---
description: >-
  This endpoint can be used to fetch the list of supported vendor bank account
  details where the user will send the funds to when performing a Buy request.
---

# List Payment Vendors

## Get all vendors

{% hint style="info" %}
Use this endpoint to get all Vendors\
\
&#xNAN;**`GET api.ngnc.online`/transactions/v1/**&#x76;endors **(LIVE)**\
\
&#xNAN;**`GET api.ngnc.online`/transactions/v1/**&#x74;est-vendors **(TEST)**
{% endhint %}

{% tabs %}
{% tab title="Shell" %}
{% code overflow="wrap" lineNumbers="true" %}
```bash
curl --request GET\
     --url https://api.ngnc.online/transactions/v1/vendors\
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --header 'ngnc-sec-key: NGNC_SECRET_KEY' \
```
{% endcode %}

{% code overflow="wrap" lineNumbers="true" %}
```json
RSPONSE-
    {     
        "status": "success",
        "message": "Live Vendor Accounts",
        "VendorList": [
            {
                "vendorName": "Okemdinachi Nwaejie",
                "vendorNumber": "8180789670",
                "vendorBank": "Wema Bank"
            },
            {
                "vendorName": "Christopher Okoye",
                "vendorNumber": "8180789246",
                "vendorBank": "Wema Bank"
            },
        ],
    }
```
{% endcode %}
{% endtab %}

{% tab title="JavaScript" %}
{% code overflow="wrap" lineNumbers="true" %}
```javascript
const options = {
  method: 'GET',
  headers: {
    accept: 'application/json',
    'ngnc-sec-key': 'NGNC_SECRET_KEY',
    'content-type': 'application/json'
  },
};

fetch('https://api.ngnc.online/transactions/v1/vendors', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
```
{% endcode %}
{% endtab %}

{% tab title="Python" %}
{% code title="python -m pip install requests" overflow="wrap" lineNumbers="true" %}
```python
import requests

url = "https://api.ngnc.online/transactions/v1/vendors" 

headers = {
    "accept": "application/json",
    "ngnc-sec-key": "NGNC_SECRET_KEY",
    "content-type": "application/json"
}

response = requests.post(url, headers=headers)

print(response.text)
```
{% endcode %}
{% endtab %}
{% endtabs %}

## Fetch Vendors

<mark style="color:blue;">`GET`</mark> `https://api.ngnc.online/transactions/v1/list_vendors`&#x20;

#### Headers

| Name                                           | Type   | Description             |
| ---------------------------------------------- | ------ | ----------------------- |
| ngnc-sec-key<mark style="color:red;">\*</mark> | String | Get Key from Bridge App |

{% tabs %}
{% tab title="200: OK Returns all vendors" %}

{% endtab %}

{% tab title="401: Unauthorized This happens when you input a wrong key" %}

{% endtab %}

{% tab title="404: Not Found This happens when you use a broken or invalid url" %}

{% endtab %}
{% endtabs %}
