Dokumentasi API

Base URL: https://api.onepollen.my.id · Autentikasi memakai header x-api-key (juga menerima x-apikey atau Authorization: Bearer <key>). Buat API Key di dashboard → API Key.

← Semua layanan Docs Smart-Tools →

📱 Reseller-Nokos

Endpoint untuk menjadi reseller nomor OTP. Pakai API Key bertipe Reseller-Nokos (berbeda dari Smart-Tools).

🛠️ Sedang Maintenance: Layanan Reseller Nokos sedang dalam pemeliharaan (maintenance). API Key untuk sementara tidak dapat digunakan demi keamanan. Silakan coba lagi nanti.
⚠️ Peraturan: Batas kecepatan API adalah 5 permintaan setiap 10 detik. Jika Anda melakukan spam, Cloudflare kami akan secara otomatis mengaktifkan sistem blokir sementara terhadap alamat IP Anda.
GET/api/v1/nokos/balance
Digunakan untuk menampilkan informasi tentang saldo profile yang dimiliki.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/balance', {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>', 'accept': 'application/json' }
});
const data = await res.json();
console.log(data);
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "balance": 152300,
  "currency": "IDR"
}
GET/api/v1/nokos/countries
Menampilkan daftar negara yang tersedia untuk pemesanan nomor.
Headers
x-api-key${your_key}
acceptapplication/json
Query Parameter
service_idOpsional. Filter negara berdasarkan layanan tertentu.
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/countries', {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": [
    { "id": "6", "name": "Indonesia", "code": "ID" },
    { "id": "4", "name": "Filipina", "code": "PH" }
  ]
}
GET/api/v1/nokos/operators
Menampilkan daftar operator seluler pada negara tertentu.
Headers
x-api-key${your_key}
acceptapplication/json
Query Parameter
countryWajib. ID negara, mis. "6".
provider_idOpsional. ID provider/penyedia.
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/operators?country=6', {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": [
    { "id": "telkomsel", "name": "Telkomsel" },
    { "id": "any", "name": "Acak (Semua Operator)" }
  ]
}
GET/api/v1/nokos/services
Menampilkan daftar layanan/aplikasi yang bisa dipesan beserta harganya.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/services', {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": [
    { "id": "wa", "name": "WhatsApp", "price": 1500 },
    { "id": "tg", "name": "Telegram", "price": 2000 }
  ]
}
POST/api/v1/nokos/order
Pesan Nomor — memesan satu nomor baru untuk layanan tertentu. Saldo akan dipotong sesuai harga.
Headers
x-api-key${your_key}
acceptapplication/json
Content-Typeapplication/json
Body (JSON)
service_idWajib. ID layanan, mis. "wa".
countryWajib. ID negara, mis. "6".
operatorOpsional. ID operator, default acak.
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/order', {
  method: 'POST',
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>', 'Content-Type': 'application/json' },
  body: JSON.stringify({ service_id: 'wa', country: '6', operator: 'any' })
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": {
    "orderId": "INV-8842910",
    "number": "+628113456789",
    "service": "WhatsApp",
    "price": 1500,
    "status": "waiting"
  }
}
GET/api/v1/nokos/order/:orderId
Check Pesanan — melihat detail dan status sebuah pesanan nomor.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const id = 'INV-8842910';
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/order/' + id, {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": {
    "orderId": "INV-8842910",
    "number": "+628113456789",
    "status": "waiting",
    "code": null
  }
}
POST/api/v1/nokos/order/:orderId/refresh
Ganti Status (refresh) — memuat ulang pesanan untuk mengecek kode OTP yang masuk dari nomor.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const id = 'INV-8842910';
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/order/' + id + '/refresh', {
  method: 'POST',
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": {
    "orderId": "INV-8842910",
    "status": "completed",
    "code": "839201",
    "sms": "Your WhatsApp code is 839201"
  }
}
POST/api/v1/nokos/order/:orderId/cancel
Membatalkan pesanan nomor yang belum menerima kode. Saldo akan dikembalikan jika memenuhi syarat.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const id = 'INV-8842910';
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/order/' + id + '/cancel', {
  method: 'POST',
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "message": "Pesanan dibatalkan & saldo dikembalikan.",
  "refunded": 1500
}
POST/api/v1/nokos/deposit
Deposit Create — membuat invoice top-up saldo. Kembalikan link/instruksi pembayaran.
Headers
x-api-key${your_key}
acceptapplication/json
Content-Typeapplication/json
Body (JSON)
amountWajib. Nominal deposit (angka).
payment_idOpsional. ID metode pembayaran.
Example request
text/javascript
<> Lihat Kode
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/deposit', {
  method: 'POST',
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>', 'Content-Type': 'application/json' },
  body: JSON.stringify({ amount: 50000 })
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": {
    "invoiceId": "DEP-552190",
    "amount": 50000,
    "status": "pending",
    "payUrl": "https://..."
  }
}
GET/api/v1/nokos/deposit/:invoiceId
Deposit Check — mengecek status pembayaran sebuah invoice deposit.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const id = 'DEP-552190';
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/deposit/' + id, {
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "data": { "invoiceId": "DEP-552190", "status": "paid", "amount": 50000 }
}
DELETE/api/v1/nokos/deposit/:invoiceId
Deposit Cancel — membatalkan invoice deposit yang masih pending.
Headers
x-api-key${your_key}
acceptapplication/json
Example request
text/javascript
<> Lihat Kode
const id = 'DEP-552190';
const res = await fetch('https://api.onepollen.my.id/api/v1/nokos/deposit/' + id, {
  method: 'DELETE',
  headers: { 'x-api-key': '<API_KEY_RESELLER_NOKOS>' }
});
const data = await res.json();
Example response
application/json
<> Lihat Kode
{
  "success": true,
  "message": "Invoice deposit dibatalkan."
}