gettopup merchant API
API Documentation
Public docs show the sandbox base URL for testing. Live production endpoints unlock after your API access is approved.
JSON over HTTPSSandbox examplesApprove for live
Sandbox docs mode
Sandbox base URL
https://sandbox.gettopup.com.ngPOST
/api/cablesub/Buy Cable Subscription
POST — pay TV subscription
api:readRequired headers
| Header | Value | Required |
|---|---|---|
| Authorization | Token YOUR_API_TOKEN | Yes |
| Content-Type | application/json | Yes (POST/PUT) |
| Accept | application/json | Recommended |
Endpoint
POST
https://sandbox.gettopup.com.ng/api/cablesub/Parameters / payload fields
| Field | Type | Required | Description |
|---|---|---|---|
| cablename | integer | Yes | Cable ID from GET /api/get/cable/ |
| cableplan | integer | Yes | Plan ID |
| smart_card_number | string | Yes | Validated IUC number |
Code samples
cURL
curl -X POST "https://sandbox.gettopup.com.ng/api/cablesub/" \
-H "Authorization: Token YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"cablename":1,"cableplan":5,"smart_card_number":"1234567890"}'Request body (JSON)
JSON
{
"cablename": 1,
"cableplan": 5,
"smart_card_number": "1234567890"
}Response sample (200)
JSON
{
"ident": "CABLE1234567890",
"Status": "successful",
"plan_amount": "2500.00",
"customer_name": "JOHN DOE"
}Sandbox examples only — live host and production keys appear after API access is approved.