Misc API
Look up supported services.
Environment
The examples below use sandbox: https://sandbox.payscribe.ng/api/v1. Switch to https://api.payscribe.ng/api/v1 only with a production key after completing the go-live checklist.
List Services
Fetch available services grouped by category.
GET /misc/services?group_by=betting
Query Parameters
| Field | Type | Required | Description |
|---|---|---|---|
group_by | string | No | One of airtime, data, tv, electricity, recharge_card, betting, internet, education, voucher. Omit it (or pass all) to fetch every service across categories. |
- cURL
- Node.js
- Python
- Go
curl -X GET "https://sandbox.payscribe.ng/api/v1/misc/services?group_by=betting" \
-H "Authorization: Bearer $PAYSCRIBE_API_KEY"
const response = await fetch('https://sandbox.payscribe.ng/api/v1/misc/services?group_by=betting', {
method: 'GET',
headers: {Authorization: `Bearer ${process.env.PAYSCRIBE_API_KEY}`},
});
const result = await response.json().catch(() => null);
if (!response.ok) throw new Error(`Payscribe request failed: ${response.status}`);
console.log(result);
import os
import requests
response = requests.get(
'https://sandbox.payscribe.ng/api/v1/misc/services?group_by=betting',
headers={'Authorization': f"Bearer {os.environ['PAYSCRIBE_API_KEY']}"},
timeout=20,
)
response.raise_for_status()
print(response.json())
package main
import (
"fmt"
"io"
"net/http"
"os"
)
func main() {
var body io.Reader
request, err := http.NewRequest(http.MethodGet, "https://sandbox.payscribe.ng/api/v1/misc/services?group_by=betting", body)
if err != nil { panic(err) }
request.Header.Set("Authorization", "Bearer "+os.Getenv("PAYSCRIBE_API_KEY"))
response, err := http.DefaultClient.Do(request)
if err != nil { panic(err) }
defer response.Body.Close()
responseBody, _ := io.ReadAll(response.Body)
if response.StatusCode < 200 || response.StatusCode > 299 { panic(fmt.Sprintf("Payscribe request failed: %s", response.Status)) }
fmt.Println(string(responseBody))
}
Response
{
"status": true,
"description": "Service looked up successfully!",
"message": {
"details": [
{
"id": "bet9ja",
"title": "Bet9ja",
"slug": "bet9ja",
"category": "betting",
"active": true,
"logo_url": "https://res.cloudinary.com/.../bet9ja.png"
}
]
},
"status_code": 200
}
message.details is a flat array (not wrapped in an object with total/page, unlike the paginated list endpoints elsewhere in this API) — there is no pagination. Note that id here is the provider's short network code (e.g. bet9ja), not a numeric database ID.
An unrecognized group_by value returns a 400 listing the accepted values; a group_by with no matching services returns 404 Result not found!.
Was this page helpful?