API v1
API Documentation
Query SIM and CNIC data with a single HTTP request. JSON responses, no key required.
Base URL: {BASE}
GET
SIM Search
{BASE}/api/search?number=03001234567
Returns owner details for a mobile number.
| Param | Type | Description |
|---|---|---|
| number | string | Mobile number, 03XXXXXXXXX |
curl
curl "{BASE}/api/search?number=03001234567"
python
import requests
r = requests.get("{BASE}/api/search",
params={"number": "03001234567"})
print(r.json())
javascript
const r = await fetch("{BASE}/api/search?number=03001234567");
const data = await r.json();
console.log(data);
GET
CNIC Search
{BASE}/api/cnic?cnic=3520212345671
Returns details linked with a 13 digit CNIC.
| Param | Type | Description |
|---|---|---|
| cnic | string | 13 digit CNIC, no dashes |
curl
curl "{BASE}/api/cnic?cnic=3520212345671"
python
import requests
r = requests.get("{BASE}/api/cnic",
params={"cnic": "3520212345671"})
print(r.json())
javascript
const r = await fetch("{BASE}/api/cnic?cnic=3520212345671");
const data = await r.json();
console.log(data);
Responses
200 · Success
json
{
"success": true,
"query": "03001234567",
"count": 1,
"results": [
{ "...": "..." }
],
"message": "OK"
}404 · No data
json
{
"success": false,
"query": "03001234567",
"count": 0,
"results": [],
"message": "SIM after 2022. Please check details of SIM before 2022."
}Status codes
| Code | Meaning |
|---|---|
| 200 | Data found |
| 400 | Invalid number / CNIC |
| 404 | No data found |
| 502 | Upstream service error |