Balance
Mengembalikan saldo dompet USD terselesaikan Anda saat ini. Setiap permintaan membaca saldo selesai terbaru; batas rate API normal tetap berlaku.
POST
https://notpanel.com/api/v3action=balanceAPI key diperlukanDibatasi rate (akun bersama + IP + action)Body:
application/x-www-form-urlencodedParameter
| Nama | Tipe | Deskripsi |
|---|---|---|
| keyWajib | string | API key Anda. |
| actionWajib | string | Harus berupa string literal "balance". |
Contoh request
Ganti YOUR_API_KEY dengan key yang dibuat di halaman API dashboard Anda.
curl -X POST https://notpanel.com/api/v3 \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "key=YOUR_API_KEY&action=balance"const res = await fetch("https://notpanel.com/api/v3", {
method: "POST",
headers: { "Content-Type": "application/x-www-form-urlencoded" },
body: new URLSearchParams({
key: "YOUR_API_KEY",
action: "balance",
}),
});
const data = await res.json();
console.log(data);import requests
res = requests.post(
"https://notpanel.com/api/v3",
data={
"key": "YOUR_API_KEY",
"action": "balance",
},
)
print(res.json())<?php
$body = http_build_query([
'key' => 'YOUR_API_KEY',
'action' => 'balance',
]);
$response = file_get_contents('https://notpanel.com/api/v3', false, stream_context_create([
'http' => [
'method' => 'POST',
'header' => "Content-Type: application/x-www-form-urlencoded\r\n",
'content' => $body,
'ignore_errors' => true,
],
]));
print_r(json_decode($response, true));
Contoh response
{
"balance": "47.32",
"currency": "USD"
}Error umum
| Status | Body | Penyebab |
|---|---|---|
| 403 | {"error":"Account suspended"} | Akun tidak aktif. |