AfroPin Developers
Postman Sign in Get test keys

Where cards can be spent

List the brand stores where your customers can redeem the PINs you sell. Use it to show customers where to spend a PIN.

GET https://afropin.com/api/v1/reseller/brand-stores

HMAC-signed request with a unique Idempotency-Key header. Authentication

With an SDK
PHP$afropin->reseller->brandStores->list($params)
Node.jsafropin.reseller.brandStores.list(params)
Pythonafropin.reseller.brand_stores.list(params)
Javaafropin.reseller().brandStores().list(params)

Query parameters

page integer | "all" Optional

Page to return, starting at 1. Pass all to return every location without pagination.

limit integer Optional

Locations per page. Defaults to 20.

Response fields

id
Location ID.
title
Store name.
latitude, longitude
Coordinates, as strings.
address
Street address.
country
ISO 3166-1 alpha-2 country code.
state
State code within the country.
city, postal_code
City and postal or ZIP code.
Only active locations, in the mode of your API key, belonging to brands that accept at least one of your active products, are returned. Paged responses also carry a paging object; it is left out when page=all.

Request

GET /api/v1/reseller/brand-stores?page=1&limit=20

Response 200

{
    "ok": true,
    "data": [
        {
            "id": "b7e2c4a1-3f58-4d9e-8a61-2c0f9b4d7e13",
            "title": "Shoprite Lekki",
            "latitude": "6.4474",
            "longitude": "3.4723",
            "address": "Admiralty Way, Lekki Phase 1",
            "country": "NG",
            "city": "Lagos",
            "state": "LA",
            "postal_code": "106104"
        }
    ],
    "paging": {
        "page": 1,
        "pages": 1,
        "per_page": 20,
        "total": 1,
        "next": null,
        "previous": null
    }
}

Errors

Failed requests return a stable code with a translated message. Branch on code, never on the message.

{
    "ok": false,
    "error": {
        "code": "invalid_api_key",
        "message": "This API key is unknown, revoked or expired, or live access is not switched on",
        "fields": null
    }
}
All error codes →