接口文档

基础说明

接口地址
--
请求方式
除标注外均为 JSON,POST 需带 Content-Type: application/json
鉴权
请求头 X-API-Key: 您的密钥(也支持 ?key= 参数)
返回格式
{"code":0,"msg":"ok","data":{...}},code 非 0 即为错误,msg 为原因

1. 获取手机号

POST/api/number/get
{
  "game_id": 1000,        // 项目ID,必填
  "country": "852",       // 国家代码,必填
  "timeout": 300,         // 可选,等待验证码的时长(秒),默认 300
  "mobile": "",           // 可选,指定手机号
  "seq": ""               // 可选,指定号段
}
{
  "code": 0,
  "msg": "ok",
  "data": {
    "order_id": "o3f2a1b9c8d7e6f5",
    "phone": "8525xxxxxxx",
    "game_name": "Telegram (TG)",
    "country": "香港",
    "cost": "1.00",
    "status": "waiting",
    "expire_at": "2026-10-27T12:00:00+08:00",
    "wait_secs": 300
  }
}

2. 获取验证码

GET/api/code/get?order_id=xxx&wait=25

wait 为可选长轮询秒数,最长 60;不传则立即返回当前状态。status 为 waiting 时表示尚未收到短信。

{
  "code": 0,
  "msg": "ok",
  "data": {
    "order_id": "o3f2a1b9c8d7e6f5",
    "phone": "8525xxxxxxx",
    "status": "got",
    "status_cn": "已收到验证码",
    "code": "123456",
    "sms": "Your verification code is 123456",
    "expire_at": "2026-10-27T12:00:00+08:00"
  }
}

3. 释放号码

POST/api/order/release
{"order_id": "o3f2a1b9c8d7e6f5"}

已收到短信的订单不允许释放;超过等待时长未收到短信的订单由服务端自动释放。

4. 加黑号码

POST/api/order/black
{"order_id": "o3f2a1b9c8d7e6f5"}

5. 发送短信

POST/api/order/send
{
  "order_id": "o3f2a1b9c8d7e6f5",
  "receiver": "8613800000000",
  "content": "短信内容"
}

6. 订单列表

GET/api/orders?limit=50&status=got

仅返回当前密钥下的订单。

7. 余额

GET/api/balance
{"code":0,"msg":"ok","data":{"balance":"179.00","currency":"CNY"}}

8. 价目表

GET/api/price?game_id=1000&country_id=852
{"code":0,"msg":"ok","data":{"total":1,"items":[
  {"game_id":1000,"game_name":"Telegram (TG)","price":"1.00","country_id":852,"country":"香港"}
]}}

9. 项目列表

GET/api/games

返回所有可用项目及其最低单价。

状态说明

waiting
已取号,等待验证码
got
已收到验证码
released
调用方已释放
timeout
等待超时,系统自动释放
black
号码已加黑