API hujjatlari
Standart SMM panel API — boshqa panellar, botlar va skriptlarni ulash uchun.
- API URL
https://24service.uz/api/v2- Usul
- POST (form-data / x-www-form-urlencoded / JSON)
- Kalit
- Kalitni shu yerda yarating: API (dasturchilar)
- Javob
- JSON · xatolar formati
{"error": "…"}
services — xizmatlar ro‘yxati
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | services |
Javob namunasi
[{"service": 1024, "name": "Telegram Members", "type": "Default", "category": "Telegram Members", "rate": "6500.00", "min": "10", "max": "100000", "refill": true, "cancel": true, "dripfeed": true}] add — buyurtma berish
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | add |
| service | xizmat ID |
| link | havola |
| quantity | miqdor |
| runs | drip-feed: necha marta (ixtiyoriy) |
| interval | drip-feed: oraliq, daqiqa (ixtiyoriy) |
| comments | izohlar, har qatorga bittadan (Custom Comments uchun) |
Javob namunasi
{"order": 23501} status — buyurtma holati (bitta yoki 100 tagacha)
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | status |
| order | buyurtma ID |
| orders | vergul bilan buyurtma ID lar (100 tagacha) |
Javob namunasi
{"charge": "6500.00", "start_count": "3572", "status": "Partial", "remains": "157", "currency": "UZS"} refill — refill so‘rash
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | refill |
| order | buyurtma ID |
| orders | vergul bilan buyurtma ID lar (100 tagacha) |
Javob namunasi
{"refill": "1"} refill_status — refill holati
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | refill_status |
| refill | refill ID |
| refills | vergul bilan refill ID lar |
Javob namunasi
{"status": "Completed"} cancel — bekor qilish
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | cancel |
| orders | vergul bilan buyurtma ID lar (100 tagacha) |
Javob namunasi
[{"order": 9, "cancel": 1}, {"order": 2, "cancel": {"error": "Incorrect order ID"}}] balance — balans
| Parametr | Tavsif |
|---|---|
| key | API kalitingiz |
| action | balance |
Javob namunasi
{"balance": "100500.00", "currency": "UZS"} Kod namunalari
PHP
<?php
$ch = curl_init('https://24service.uz/api/v2');
curl_setopt_array($ch, [CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true,
CURLOPT_POSTFIELDS => http_build_query(['key' => 'YOUR_KEY', 'action' => 'add', 'service' => 1024, 'link' => 'https://t.me/channel', 'quantity' => 1000])]);
$result = json_decode(curl_exec($ch), true); Python
import requests
r = requests.post('https://24service.uz/api/v2', data={'key': 'YOUR_KEY', 'action': 'status', 'order': 23501})
print(r.json()) Node.js
const r = await fetch('https://24service.uz/api/v2', { method: 'POST', body: new URLSearchParams({ key: 'YOUR_KEY', action: 'balance' }) });
console.log(await r.json()); Virtual raqamlar API (SMS-Activate formati)
SMS-Activate / HeroSMS bilan ishlaydigan botlar va skriptlar uchun tayyor: faqat manzil va kalitni almashtiring. Kalit — yuqoridagi bilan bir xil.
- API URL
https://24service.uz/api/sms- Usul
- POST
- Kalit
api_key— api_key ni POST body yoki X-Api-Key headerda yuboring (URL ichida qabul qilinmaydi).- Javob
- Oddiy matn (ACCESS_…, STATUS_…) yoki JSON
Odatiy ketma-ketlik: getPrices → getNumber → har 5–10 soniyada getStatus → kod kelgach setStatus=6. Kod kelmasa setStatus=8 — pul balansga qaytadi (raqam olingach 2 daqiqadan keyin).
getBalance — Balans
Javob namunasi
ACCESS_BALANCE:125000.00
getCountries — Davlatlar ro'yxati
Javob namunasi
{"0": {"id": 0, "eng": "Russia", "rus": "Россия"}, "6": {"id": 6, "eng": "Indonesia", "rus": "Индонезия"}} getServicesList — Xizmatlar (kodlar)
Javob namunasi
{"status": "success", "services": [{"code": "tg", "name": "Telegram"}, {"code": "wa", "name": "WhatsApp"}]} getPrices — Narx va mavjud raqamlar soni (sizning valyutangizda)
| Parametr | Tavsif |
|---|---|
| service | Xizmat kodi (masalan tg, ig, wa) |
| country | Davlat ID (getCountries dan) |
Javob namunasi
{"6": {"tg": {"cost": 4200.00, "count": 1530}}} getNumber — Raqam olish (pul yechiladi)
| Parametr | Tavsif |
|---|---|
| service | Xizmat kodi (masalan tg, ig, wa) |
| country | Davlat ID (getCountries dan) |
| maxPrice | Ixtiyoriy: maksimal narx — qimmat bo'lsa WRONG_MAX_PRICE |
Javob namunasi
ACCESS_NUMBER:5821:6281234567890
getNumberV2 — Raqam olish, JSON javob
| Parametr | Tavsif |
|---|---|
| service | Xizmat kodi (masalan tg, ig, wa) |
| country | Davlat ID (getCountries dan) |
| maxPrice | Ixtiyoriy: maksimal narx — qimmat bo'lsa WRONG_MAX_PRICE |
Javob namunasi
{"activationId": "5821", "phoneNumber": "6281234567890", "activationCost": 4200.00, "currency": "UZS", "countryCode": "6", "activationEndTime": "2026-10-05 12:40:00"} getStatus — SMS kodini tekshirish
| Parametr | Tavsif |
|---|---|
| id | Aktivatsiya ID |
Javob namunasi
STATUS_WAIT_CODE STATUS_OK:12345 STATUS_CANCEL
setStatus — Holatni o'zgartirish: 3 — yana SMS, 6 — yakunlash, 8 — bekor qilish (pul qaytadi)
| Parametr | Tavsif |
|---|---|
| id | Aktivatsiya ID |
| status | 3 / 6 / 8 |
Javob namunasi
ACCESS_RETRY_GET · ACCESS_ACTIVATION · ACCESS_CANCEL
getActiveActivations — Faol raqamlar
Javob namunasi
{"status": "success", "activeActivations": [{"activationId": "5821", "phoneNumber": "6281234567890", "smsCode": null, "status": "STATUS_WAIT_CODE"}]} Xatolar: BAD_KEY, NO_BALANCE (balans yetmaydi), NO_NUMBERS, BAD_SERVICE, BAD_COUNTRY, NO_ACTIVATION, EARLY_CANCEL_DENIED, CHANNELS_LIMIT, TOO_MANY_REQUESTS.
Python
import requests, time
URL, KEY = 'https://24service.uz/api/sms', 'YOUR_KEY'
api = lambda **p: requests.post(URL, data={'api_key': KEY, **p}).text
_, aid, phone = api(action='getNumber', service='tg', country=6).split(':')
while not (s := api(action='getStatus', id=aid)).startswith('STATUS_OK'):
time.sleep(5)
print(phone, s.split(':', 1)[1]); api(action='setStatus', id=aid, status=6) Cheklovlar
- Har kalitga daqiqasiga 300 ta so‘rov.
- Kalitni faqat POST tanasida yuboring — URL da yuborilgan kalit rad etiladi.
- Takroriy buyurtmadan himoya: Idempotency-Key header yoki idempotency_key parametri.