Developers
Developer API
Automate buying numbers and fetching OTP codes with a clean REST API and a single key.
Base URL
Get your API keyhttps://xthonvirtual.store/api/v201
Authentication
Send your personal API key in a header with every request. Get it from the bot under π API.
X-API-Key: YOUR_API_KEY02
Quick start
Check your balance, then: list services β buy a number β poll for the code.
curl -X GET "https://xthonvirtual.store/api/v2/balance" \
-H "X-API-Key: YOUR_API_KEY"Endpoints
GET
/balanceGet your current balance and bonus tier.
curl -X GET "https://xthonvirtual.store/api/v2/balance" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": { "balance": "12.50", "bonus": 10 }
}GET
/servicesList active services with their price and live stock.
curl -X GET "https://xthonvirtual.store/api/v2/services" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": [
{ "id": "8f3cβ¦", "name": "Telegram", "price": "1.20", "stock": 42 }
]
}POST
/services/{service_id}/buyReserve and buy one number from a service.
curl -X POST "https://xthonvirtual.store/api/v2/services/{service_id}/buy" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": {
"id": "tx_91aβ¦", "status": "PENDING",
"price": "1.20", "number": "+15550001", "code": null
}
}GET
/transactions/{id}Fetch a transaction (number) you own.
curl -X GET "https://xthonvirtual.store/api/v2/transactions/{id}" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": { "id": "tx_91aβ¦", "status": "PENDING", "number": "+15550001", "code": null }
}GET
/transactions/{id}/codePoll for the OTP code β returns null until it arrives.
curl -X GET "https://xthonvirtual.store/api/v2/transactions/{id}/code" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": { "id": "tx_91aβ¦", "status": "SUCCEEDED", "code": "54321" }
}POST
/transactions/{id}/cancelRefund a PENDING number that never received a code.
curl -X POST "https://xthonvirtual.store/api/v2/transactions/{id}/cancel" \
-H "X-API-Key: YOUR_API_KEY"Response
{
"ok": true,
"data": { "refunded": "1.20" }
}Wholesale via API tokens
Buying at volume? Use API tokens to purchase numbers in bulk programmatically, with the best per-unit pricing and dedicated support for resellers.
Contact us for wholesale04
Status codes
| 200 | Success |
| 401 | Missing or invalid API key |
| 402 | Insufficient balance |
| 404 | Not found |
| 409 | Out of stock |