จุดเชื่อมต่อในหน้านี้
GET /v1/catalog/coins: สกุลเงินคริปโตและเครือข่ายที่รองรับ (พร้อมที่อยู่ฝากเงินแบบกำหนดตายตัว)POST /v1/topups: เริ่มเติมเงินเข้ายอดคงเหลือด้วยคริปโต (ที่อยู่กำหนดตายตัว จำนวนเงินที่แน่นอน)POST /v1/topups/{topUpId}/txid: แจ้งว่าส่งการชำระเงินแล้ว (ไม่บังคับระบุ TXID)GET /v1/topups/{topUpId}: ดูรายการเติมเงิน (ตรวจสอบสถานะล่าสุด)GET /v1/topups: แสดงรายการเติมเงินด้วยคริปโต
URL พื้นฐาน https://localserpproxy.com/api/v1 ดูข้อมูลการยืนยันตัวตน ข้อผิดพลาด และขีดจำกัดได้ที่ ภาพรวม API
สกุลเงินดิจิทัลและเครือข่ายที่รองรับ (พร้อมที่อยู่ฝากเงินแบบคงที่)
GET/v1/catalog/coins
สาธารณะ: ไม่ต้องใช้คีย์ API
การตอบกลับ 200 OK
{
"data": [
{
"code": "BTC",
"name": "Bitcoin",
"networks": [
{
"id": "bitcoin",
"name": "Bitcoin",
"confirmationsRequired": 2,
"estimatedMinutes": null,
"memoRequired": false,
"address": "DEPOSIT_ADDRESS"
}
]
}
]
}ตัวอย่างโค้ด
curl -s "https://localserpproxy.com/api/v1/catalog/coins"import os
import requests
API = "https://localserpproxy.com/api/v1"
r = requests.get(f"{API}/catalog/coins", timeout=30)
r.raise_for_status()
print(r.json())// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';
const res = await fetch(`${API}/catalog/coins`);
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());เริ่มเติมเงินเข้ายอดคงเหลือด้วยคริปโต (ที่อยู่คงที่ จำนวนเงินที่แน่นอน)
POST/v1/topups
amountUsd≥ 25.00 USD และ ≤ จำนวนสูงสุด (ค่าเริ่มต้น 10,000.00):422บนamountUsdมิฉะนั้นcoin+networkต้องเป็นหนึ่งในGET /v1/catalog/coins(มิฉะนั้น409 coin_unavailable)- ส่งคืน
addressแบบ คงที่ ของเครือข่าย และamountCryptoที่แน่นอน =amountUsd/rateโดยปัด ขึ้น ตามจำนวนตำแหน่งทศนิยมของเหรียญ (BTC/LTC/ETH/SOL 8 ตำแหน่ง, USDT/USDC 6 ตำแหน่ง) พร้อมเพิ่มส่วนต่างเล็กน้อยที่ไม่ซ้ำกันในหลักท้าย เพื่อไม่ให้การเติมเงินที่ยังเปิดอยู่ 2 รายการบนเครือข่ายเดียวกันใช้จำนวนเงินเดียวกันrateจะถูกล็อกจนถึงexpiresAt(30 นาที);txidDeadline=expiresAt+ 72 h. purchaseไม่บังคับ (เนื้อหาเดียวกับPOST /v1/orders): ตรวจสอบและคำนวณราคาในขณะนี้ (422โดยเติมชื่อฟิลด์นำหน้าด้วยpurchase.,409 plan_unavailable…)amountUsdต้องครอบคลุมยอดรวมpurchase− ยอดคงเหลือปัจจุบัน (422 too_smallบนamountUsd) เมื่อเติมเงินเข้ายอดแล้ว ระบบจะสั่งซื้อจากยอดคงเหลือในธุรกรรมเดียวกัน;purchase.statusจะเปลี่ยนเป็นcompleted(พร้อมorderId) หรือfailed(failureReason; เงินยังคงอยู่ในยอดคงเหลือ)
การยืนยันตัวตน: ใช้คีย์ API ในส่วนหัว Authorization: Bearer API_KEY
พารามิเตอร์
| ชื่อ | ใน | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|---|
Idempotency-Key | header | string | ไม่ | คีย์ที่ไม่ซ้ำกัน (เช่น UUID) สำหรับลองส่ง POST ซ้ำอย่างปลอดภัย เก็บไว้ 24 h — สูงสุด 128 ตัวอักษร |
เนื้อหาคำขอ
| ฟิลด์ | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|
amountUsd | string (USD, 2 decimals) | ใช่ | จำนวน USD ที่ต้องการเติม: ≥ 25.00, ≤ 10,000.00 โดยค่าเริ่มต้น |
coin | string | ใช่ | — |
network | string | ใช่ | — |
purchase | object | ไม่ | แผนการซื้อจากยอดคงเหลือเมื่อเติมเงินเข้ายอดแล้ว (เนื้อหาเดียวกับ POST /v1/orders) |
{
"amountUsd": "50.00",
"coin": "USDT",
"network": "tron"
}{
"amountUsd": "25.00",
"coin": "BTC",
"network": "bitcoin",
"purchase": {
"planId": "res-10",
"quantity": 1
}
}การตอบกลับ 201 Created
{
"id": "top_7d2kq9x1",
"status": "verifying",
"final": false,
"amountUsd": "25.00",
"coin": "USDT",
"network": "tron",
"address": "DEPOSIT_ADDRESS",
"amountCrypto": "25.000137",
"rate": "1.00",
"paymentUri": "PAYMENT_URI",
"expiresAt": "2026-10-05T14:33:11Z",
"txidDeadline": "2026-10-08T14:33:11Z",
"confirmationsRequired": 20,
"confirmations": 7,
"txid": "9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"txidSubmittedAt": "2026-10-05T14:09:42Z",
"amountReceivedCrypto": "25.000137",
"explorerUrl": "https://tronscan.org/#/transaction/9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"creditedUsd": null,
"creditedAt": null,
"rejection": null,
"purchase": {
"planId": "res-10",
"planName": "Local team",
"quantity": 1,
"options": {},
"promoCode": null,
"total": "7.50",
"status": "pending",
"orderId": null,
"failureReason": null
},
"createdAt": "2026-10-05T14:03:11Z"
}ตัวอย่างโค้ด
curl -s -X POST "https://localserpproxy.com/api/v1/topups" \
-H "Authorization: Bearer $API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{"amountUsd":"50.00","coin":"USDT","network":"tron"}'import os, uuid
import requests
API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}", "Idempotency-Key": str(uuid.uuid4())}
r = requests.post(f"{API}/topups", headers=HEADERS, json={"amountUsd": "50.00", "coin": "USDT", "network": "tron"}, timeout=30)
r.raise_for_status()
print(r.json())// Node.js 18+ (built-in fetch), ES module
import { randomUUID } from 'node:crypto';
const API = 'https://localserpproxy.com/api/v1';
const res = await fetch(`${API}/topups`, {
method: 'POST',
headers: { Authorization: `Bearer ${process.env.API_KEY}`, 'Idempotency-Key': randomUUID(), 'Content-Type': 'application/json' },
body: JSON.stringify({ amountUsd: '50.00', coin: 'USDT', network: 'tron' }),
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());แจ้งว่าส่งการชำระเงินแล้ว (TXID ไม่บังคับ)
POST/v1/topups/{topUpId}/txid
แจ้งว่าส่งการชำระเงินแล้วเมื่อเงินออกจากกระเป๋าหรือ exchange ของคุณ: นี่คือเวอร์ชัน API ของปุ่ม “ฉันส่งเงินแล้ว” ไม่จำเป็นต้องระบุรหัสธุรกรรม (TXID): ส่งเนื้อหาว่าง ({}) หรือเพิ่ม txid หากมี ระบบจะจับคู่การชำระเงินกับรายการเติมเงินนี้โดยใช้จำนวนเงินที่แน่นอน (amountCrypto) บนเครือข่ายและที่อยู่ของรายการเติมเงิน ดังนั้นโปรดส่งจำนวนเงินให้ตรงตามที่ระบุ
ส่งรายงานได้ขณะที่รายการเติมเงินมีสถานะ awaiting_payment, expired หรือ rejected และก่อน txidDeadline (expiresAt + 72 h): การรายงานล่าช้าไม่ทำให้การชำระเงินสูญหาย หากระบุ txid ระบบจะตรวจสอบรูปแบบตามเครือข่าย (422 บน txid) และต้องไม่มีรายการเติมเงินอื่นอ้างสิทธิ์ใช้รายการนี้ (409 txid_already_used) หากรายการเติมเงินปิดแล้ว ระบบจะส่งคืน 409 topup_closed จากนั้นรายการเติมเงินจะมีสถานะ verifying ระหว่างตรวจสอบการชำระเงินบนบล็อกเชน และสิ้นสุดเป็น credited เมื่อเครือข่ายยืนยันธุรกรรมแล้ว หรือเป็น rejected (พร้อม rejection)
การยืนยันตัวตน: ใช้คีย์ API ในส่วนหัว Authorization: Bearer API_KEY
พารามิเตอร์
| ชื่อ | ใน | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|---|
topUpId | path | string | ใช่ | — |
เนื้อหาคำขอ
| ฟิลด์ | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|
txid | string | ไม่ | ไม่บังคับ แฮชธุรกรรม: 64 ตัวอักษรฐานสิบหก (bitcoin, litecoin, tron), 0x + 64 ตัวอักษรฐานสิบหก (ethereum), ลายเซ็น base58 (solana) หากเว้นว่างหรือไม่ระบุ ระบบจะจับคู่การชำระเงินด้วยจำนวนเงินที่แน่นอน — สูงสุด 128 ตัวอักษร |
{}{
"txid": "4a5e1e4baab89f3a32518a88c31bc87f618f76673e2cc77ab2127b7afdeda33b"
}การตอบกลับ 200 OK
{
"id": "top_7d2kq9x1",
"status": "verifying",
"final": false,
"amountUsd": "25.00",
"coin": "USDT",
"network": "tron",
"address": "DEPOSIT_ADDRESS",
"amountCrypto": "25.000137",
"rate": "1.00",
"paymentUri": "PAYMENT_URI",
"expiresAt": "2026-10-05T14:33:11Z",
"txidDeadline": "2026-10-08T14:33:11Z",
"confirmationsRequired": 20,
"confirmations": 7,
"txid": "9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"txidSubmittedAt": "2026-10-05T14:09:42Z",
"amountReceivedCrypto": "25.000137",
"explorerUrl": "https://tronscan.org/#/transaction/9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"creditedUsd": null,
"creditedAt": null,
"rejection": null,
"purchase": {
"planId": "res-10",
"planName": "Local team",
"quantity": 1,
"options": {},
"promoCode": null,
"total": "7.50",
"status": "pending",
"orderId": null,
"failureReason": null
},
"createdAt": "2026-10-05T14:03:11Z"
}ตัวอย่างโค้ด
curl -s -X POST "https://localserpproxy.com/api/v1/topups/top_7d2kq9x1/txid" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{}'import os
import requests
API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}
r = requests.post(f"{API}/topups/top_7d2kq9x1/txid", headers=HEADERS, json={}, timeout=30)
r.raise_for_status()
print(r.json())// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';
const res = await fetch(`${API}/topups/top_7d2kq9x1/txid`, {
method: 'POST',
headers: { Authorization: `Bearer ${process.env.API_KEY}`, 'Content-Type': 'application/json' },
body: JSON.stringify({}),
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());เติมเงิน (ตรวจสอบสถานะแบบเรียลไทม์)
GET/v1/topups/{topUpId}
ตรวจสอบเส้นทางนี้เพื่อติดตามการเติมเงิน: ทุก 10 วินาทีขณะที่ status = verifying ทุก 30 วินาทีระหว่างรอการชำระเงิน และหยุดเมื่อ final = true การเติมเงินจะเปลี่ยนเป็น expired หากไม่มีการแจ้งว่าส่งการชำระเงินแล้วก่อน expiresAt โดยยังแจ้งได้จนถึง txidDeadline
การยืนยันตัวตน: ใช้คีย์ API ในส่วนหัว Authorization: Bearer API_KEY
พารามิเตอร์
| ชื่อ | ใน | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|---|
topUpId | path | string | ใช่ | — |
การตอบกลับ 200 OK
{
"id": "top_7d2kq9x1",
"status": "verifying",
"final": false,
"amountUsd": "25.00",
"coin": "USDT",
"network": "tron",
"address": "DEPOSIT_ADDRESS",
"amountCrypto": "25.000137",
"rate": "1.00",
"paymentUri": "PAYMENT_URI",
"expiresAt": "2026-10-05T14:33:11Z",
"txidDeadline": "2026-10-08T14:33:11Z",
"confirmationsRequired": 20,
"confirmations": 7,
"txid": "9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"txidSubmittedAt": "2026-10-05T14:09:42Z",
"amountReceivedCrypto": "25.000137",
"explorerUrl": "https://tronscan.org/#/transaction/9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"creditedUsd": null,
"creditedAt": null,
"rejection": null,
"purchase": {
"planId": "res-10",
"planName": "Local team",
"quantity": 1,
"options": {},
"promoCode": null,
"total": "7.50",
"status": "pending",
"orderId": null,
"failureReason": null
},
"createdAt": "2026-10-05T14:03:11Z"
}ตัวอย่างโค้ด
curl -s "https://localserpproxy.com/api/v1/topups/top_7d2kq9x1" \
-H "Authorization: Bearer $API_KEY"import os
import requests
API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}
r = requests.get(f"{API}/topups/top_7d2kq9x1", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';
const res = await fetch(`${API}/topups/top_7d2kq9x1`, {
headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());แสดงรายการเติมเงินด้วยคริปโต
GET/v1/topups
การยืนยันตัวตน: ใช้คีย์ API ในส่วนหัว Authorization: Bearer API_KEY
พารามิเตอร์
| ชื่อ | ใน | ประเภท | จำเป็น | คำอธิบาย |
|---|---|---|---|---|
page | query | integer | ไม่ | ≥ 1 ค่าเริ่มต้น 1 |
perPage | query | integer | ไม่ | 1–100 ค่าเริ่มต้น 20 |
status | query | awaiting_payment · verifying · credited · rejected · expired | ไม่ | final = เติมเข้าบัญชีแล้ว หรือหมดอายุ / ถูกปฏิเสธหลัง txidDeadline |
การตอบกลับ 200 OK
{
"data": [
{
"id": "top_7d2kq9x1",
"status": "verifying",
"final": false,
"amountUsd": "25.00",
"coin": "USDT",
"network": "tron",
"address": "DEPOSIT_ADDRESS",
"amountCrypto": "25.000137",
"rate": "1.00",
"paymentUri": "PAYMENT_URI",
"expiresAt": "2026-10-05T14:33:11Z",
"txidDeadline": "2026-10-08T14:33:11Z",
"confirmationsRequired": 20,
"confirmations": 7,
"txid": "9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"txidSubmittedAt": "2026-10-05T14:09:42Z",
"amountReceivedCrypto": "25.000137",
"explorerUrl": "https://tronscan.org/#/transaction/9d2e5c0b1f7a4e3d8c6b2a1f0e9d8c7b6a5f4e3d2c1b0a9f8e7d6c5b4a3f41c7",
"creditedUsd": null,
"creditedAt": null,
"rejection": null,
"purchase": {
"planId": "res-10",
"planName": "Local team",
"quantity": 1,
"options": {},
"promoCode": null,
"total": "7.50",
"status": "pending",
"orderId": null,
"failureReason": null
},
"createdAt": "2026-10-05T14:03:11Z"
}
],
"pagination": {
"page": 1,
"perPage": 20,
"total": 1,
"totalPages": 1
}
}ตัวอย่างโค้ด
curl -s "https://localserpproxy.com/api/v1/topups" \
-H "Authorization: Bearer $API_KEY"import os
import requests
API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}
r = requests.get(f"{API}/topups", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';
const res = await fetch(`${API}/topups`, {
headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());