AfroPin Developers
Postman Sign in Get test keys

What you sell

Look up a product

Get one of your PIN products: what it costs to issue, which amounts it accepts, and what holders can do with it.

GET https://afropin.com/api/v1/reseller/catalog/{catalog_id}

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

With an SDK
PHP$afropin->reseller->catalog->get($catalogId, $params)
Node.jsafropin.reseller.catalog.get(catalogId, params)
Pythonafropin.reseller.catalog.get(catalog_id, params)
Javaafropin.reseller().catalog().get(catalogId, params)

Path parameters

pin_type uuid Required

The product id from Products you can sell. It must be an active product on your account.

Response fields

id
Product ID. Send it as catalog_id to issue a PIN.
pin_type_id
The PIN template the product is built on. Brands accept PINs by template.
name, currency
Product name and the ISO 4217 currency PINs are issued in.
amount_rule
any_amount: any amount from min to max. set_amounts: only the amounts in denominations.
min, max
Smallest and largest balance a PIN can hold.
denominations
Allowed amounts for fixed products, or null.
duration
Days a PIN stays valid after it is issued, as a string.
can_top_up
Whether PINs can be topped up.
can_spend, spend_rule
Whether PINs can be redeemed at brands, and how: partial (spend in parts) or whole (the whole balance at once).
new_code_after_top_up
When true, every top-up replaces the PIN code with a new one; the old code stops working.
new_code_after_spend
Not used on your account.
sale_commission_percent
Percentage of each issue or top-up amount credited to your commission balance.
cashout_fee_percent
Not used on your account.
cashout_caps
Not used on your account.
allow_keep_code, allow_daily_limit
Whether a sale may send keep_code (the brand lets customers keep one code, and the product would otherwise change it) and daily_limit (the product is spent in parts).
logo, artwork
Image URLs you can show to customers.
description, how_to_redeem, terms
Plain-text copy for customers, or null.
categories
Category names.

Request

GET /api/v1/reseller/catalog/2c3ec3c4-b729-4d40-9a0a-80e55d683ee6

Response 200

{
    "ok": true,
    "data": {
        "id": "2c3ec3c4-b729-4d40-9a0a-80e55d683ee6",
        "pin_type_id": "7a1d5e93-0c4b-4f62-9e18-3b2a6c9d4f05",
        "name": "Everyday Shopping PIN",
        "currency": "NGN",
        "min": 1000,
        "max": 50000,
        "amount_rule": "set_amounts",
        "denominations": [
            1000,
            5000,
            10000,
            50000
        ],
        "logo": "https://example.com/storage/logo.png",
        "artwork": "https://example.com/storage/card.png",
        "description": "Spend at any participating store.",
        "how_to_redeem": "Show the PIN at checkout.",
        "terms": "Valid for 365 days from issue.",
        "categories": [
            "Groceries"
        ],
        "duration": "365",
        "can_top_up": true,
        "can_spend": true,
        "spend_rule": "partial",
        "new_code_after_top_up": false,
        "new_code_after_spend": true,
        "sale_commission_percent": 2.5,
        "cashout_fee_percent": 3,
        "cashout_caps": {
            "per_day": 100000,
            "per_week": 300000,
            "per_month": 1000000
        }
    }
}

Errors

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

404 catalog_item_not_found No item in your catalog has this catalog_id
{
    "ok": false,
    "error": {
        "code": "catalog_item_not_found",
        "message": "No item in your catalog has this catalog_id",
        "fields": null
    }
}
All error codes →