Loading HstockPlus
选择一个操作,填写参数,然后发送请求。登录后,您的 API 密钥会自动加载。
当您更改操作或参数时自动更新。
curl -X POST "https://hstockplus.net/api/v2" \
--data-urlencode "key=YOUR_API_KEY" \
--data-urlencode "action=categories"https://hstockplus.net/api/v2所有 API 请求均应通过 HTTP POST 方式发送至此端点。
限制按 API 密钥计算,仅下方两个列表操作受限。
| 行动 | 限制 |
|---|---|
| services | 1 call every 2 seconds, up to 3 calls in a row |
| products | 1 call per second, up to 3 calls in a row |
| inventory | 无限制 |
| 所有其他操作(add、status、balance 等) | 无限制 |
A limited call still returns HTTP 200, with the error below. retry_after_ms is how many milliseconds to wait before the next call. A key that keeps calling while limited (about 20 limited calls in one minute) is paused for 60 seconds.
{"error": "Rate limit exceeded", "retry_after_ms": 1400}To check price and stock of many products, call products once with productIds (up to 100 per call) instead of one services call per product. For the stock of each option of one product, use inventory.
重要提示——产品图片链接(imageUrl)
启用 Media CDN 后,服务列表、产品列表及子分类信息响应中的 imageUrl 字段将使用 CDN 域名(https://cdn.hstockplus.org/...)。请直接在应用中使用这些绝对 URL,不要替换为 hstockplus.com 或 hstockplus.net。
https://cdn.hstockplus.org/uploads/products/gmail.webp可选。目标语言代码。使用下方列出的支持代码之一。当设置为非 en 时,可翻译字段将以该语言返回。如果翻译尚不可用,API 将返回英文。
支持的语言代码
en(默认 — 省略 lang 或使用 en)zhdejapt-BRurbn-BD为 lang 参数使用这些精确值。别名:jp 可接受为 ja。
支持读取操作: categories, subcategory_info, services, products, inventory ((子产品名称)), sms_projects, 和 sms_countries. 省略语言或使用en表示英语。
服务/产品上的category和subcategory筛选参数始终使用规范英文名称,即使设置了lang也是如此。
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "lang=zh"获取所有类别及每个类别的子类别。使用这些值按类别或子类别筛选服务列表。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | categories | 是 |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=categories" \
-d "lang=zh"{
"categories": [
{
"category": "Instagram",
"subcategories": ["Followers", "Comments", "Likes"]
},
{
"category": "Email Accounts",
"subcategories": ["Gmail", "Outlook"]
}
]
}通过subcategoryId获取子类别详情,包括父类别。使用产品列表行中的subcategoryId。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | subcategory_info | 是 |
| subcategoryId | 来自产品列表的子类别ID | 是 |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=subcategory_info" \
-d "subcategoryId=674a1f77bcf86cd799439099" \
-d "lang=zh"{
"subcategoryId": "674a1f77bcf86cd799439099",
"name": "Gmail",
"slug": "gmail",
"imageUrl": "https://cdn.hstockplus.org/uploads/subcategories/gmail.webp",
"description": "Verified Gmail accounts",
"category": {
"categoryId": "674a1f77bcf86cd799439088",
"name": "Email Accounts",
"slug": "email-accounts"
}
}列出活跃店铺的基本信息、商品数量及评价星级。店铺名称已做隐私处理。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | shops | 是 |
| page | 页码(默认 1)。 | 否 |
| limit | 每页条数(默认 20)。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=shops"带分页:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=shops" \
-d "page=1" \
-d "limit=20"列出所有店铺当前可用的优惠码,以及每个优惠码的使用条件。下单时把优惠码作为 coupon 参数传给 action=add。只发给你账号的专属优惠码(例如工单里给出的批量报价)也会列出,并标记为 private。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | coupons | 是 |
| shop | 只返回该店铺的优惠码(shopId 来自 action=shops)。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=coupons"{
"coupons": [
{
"code": "SAVE10",
"type": "percentage",
"value": 10,
"shopId": "6650a1f77bcf86cd79943901",
"shopSlug": "example-shop",
"shopName": "Example Shop",
"appliesTo": "shop",
"minPurchase": 20,
"remainingUses": 87,
"expiresAt": "2026-11-30T23:59:59.000Z"
},
{
"code": "BULK500",
"type": "percentage",
"value": 5,
"shopId": "6650a1f77bcf86cd79943901",
"shopSlug": "example-shop",
"shopName": "Example Shop",
"appliesTo": "services",
"services": [110469, 110470],
"minQuantity": 100,
"quantityTiers": [
{ "minQuantity": 100, "value": 5 },
{ "minQuantity": 500, "value": 12 }
],
"maxUsesPerUser": 1,
"remainingUses": 40
}
],
"total": 2
}| 字段 | 含义 |
|---|---|
| type / value | percentage:value 为折扣百分比。fixed:value 为订单减免的美元金额。有 quantityTiers 时,value 为最低一档。 |
| appliesTo | shop:适用于该店铺的任何商品。services:只适用于 services 中列出编号的商品。店铺优惠码不适用于增长(SMM)服务。 |
| minPurchase | 订单折扣前的总额至少要达到这个美元金额。 |
| minQuantity | 订单数量至少要达到这个值。 |
| quantityTiers | 数量越多折扣越大;按你的数量达到的最高一档计算。 |
| maxDiscount | 该优惠码在一笔订单上最多减免的美元金额(仅在设有上限时返回)。 |
| maxUsesPerUser | 每个账号最多可以使用该优惠码的次数(仅在有限制时返回)。 |
| remainingUses | 所有买家合计的剩余可用次数。 |
| expiresAt | 该优惠码在此时间之后失效(不过期时不返回)。 |
| private | 为 true 表示这是只发给你账号的专属优惠码。 |
优惠码在扣除经销商折扣后的金额上再抵扣。优惠码没有某项条件时,对应的可选字段不会返回。
仅列出市场产品(不含SMM服务)。字段与服务列表中的产品行相同,包括id(产品实体ID)、service(友好服务编号)、description和imageUrl。可选参数productIds仅返回指定产品(列表中的友好服务编号和/或产品实体ID,逗号分隔或JSON数组,最多100个)。可选参数sort=sold按已支付订单数量降序排列(畅销品优先)。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | products | 是 |
| page | 页码(默认 1)。limit > 0 时生效。 | 否 |
| limit | 每页条数(默认 0 = 返回全部)。 | 否 |
| category | 按类别名称筛选(来自获取类别)。只返回该类别下的商品。 | 否 |
| subcategory | 按子类别名称筛选(来自获取类别)。只返回该子类别下的商品。 | 否 |
| shopId | 按店铺 ID 筛选(来自店铺列表)。只返回该店铺的商品。 | 否 |
| productIds | 可选的商品 ID 列表(服务编号和/或实体 id)。可用逗号分隔、JSON 数组或重复字段传入。只返回这些商品(最多 100 个)。 | 否 |
| isRecommended | 可选。设置为 true 时,仅返回 isRecommended === true 的产品。 | 否 |
| sort | 可选参数。sold = 按已支付订单数量降序排列(畅销品优先)。省略则保持默认缓存顺序。 | 否 |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products"按产品ID筛选:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "productIds=2,5,9"带分页:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "page=1" \
-d "limit=50"按类别或子类别筛选:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "category=Accounts-Email"
# Or filter by subcategory:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "subcategory=Gmail"子类别中的畅销品:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "subcategory=Twitter/X" \
-d "sort=sold" \
-d "page=1" \
-d "limit=10"仅推荐产品:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=products" \
-d "isRecommended=true"获取所有可用服务,支持可选分页。每行包含id(实体ID)、service(友好服务编号)、stock和entityType(smm或product)。可选entityType参数仅返回产品或仅返回SMM行。可选类别和子类别参数仅返回该类别或子类别中的服务(值来自获取类别API)。可选shopId参数仅返回该店铺的产品和服务(使用店铺列表中的shopId)。可选productIds参数仅返回匹配的行(友好服务编号和/或实体ID;匹配产品或SMM行)。使用action=products仅筛选产品。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | services | 是 |
| page | 页码(默认 1)。limit > 0 时生效。 | 否 |
| limit | 每页条数(默认 0 = 返回全部)。 | 否 |
| category | 按类别名称筛选(来自获取类别)。只返回该类别下的服务。 | 否 |
| subcategory | 按子类别名称筛选(来自获取类别)。只返回该子类别下的服务。 | 否 |
| shopId | 按店铺 ID 筛选(来自店铺列表)。只返回该店铺的商品和 SMM 服务。 | 否 |
| entityType | 可选筛选条件:product或smm。仅返回市场产品或仅返回SMM服务。 | 否 |
| productIds | 可选的 ID 列表(服务编号和/或实体 id)。可用逗号分隔、JSON 数组或重复字段传入。返回匹配的商品或 smm 行。只要商品请用 action=products。 | 否 |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "lang=zh"带分页:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "page=1" \
-d "limit=50"按类别或子类别筛选:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "category=Instagram"
# Or filter by subcategory:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "subcategory=Followers"按实体类型筛选:
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=services" \
-d "entityType=product"{
"services": [
{
"id": "507f1f77bcf86cd799439011",
"service": 1,
"name": "Instagram Followers",
"type": "Default",
"category": "Instagram",
"rate": "0.50",
"min": 100,
"max": 10000,
"refill": true,
"cancel": false,
"stock": 10000,
"entityType": "smm",
"autoDelivery": true
},
{
"id": "507f1f77bcf86cd799439012",
"service": 2,
"name": "Gmail Account - USA",
"type": "Default",
"category": "Accounts-Email",
"rate": "25.00",
"min": 1,
"max": 50,
"refill": false,
"cancel": false,
"stock": 50,
"entityType": "product",
"autoDelivery": true,
"description": "Verified Gmail account with recovery email",
"imageUrl": "https://cdn.hstockplus.org/uploads/products/gmail.webp",
"isRecommended": true,
"subcategoryId": "674a1f77bcf86cd799439099",
"sold": 5300,
"sellerRating": 4.0,
"sellerReviewCount": 30,
"returningBuyerRate": 0.52,
"warrantyHours": 12
}
],
"total": 150,
"page": 1,
"limit": 50,
"total_pages": 3
}每行包含 id(实体 ID)和 service(订单友好服务编号)、stock、entityType(smm 或 product)以及 autoDelivery。产品行还包含 description、imageUrl、isRecommended 和 subcategoryId。当 limit 为 0 或省略时,返回所有服务,且 page/limit 等于总数。
商品行还带有商品页上显示的数据:service 是商品编号(页面上的 #48071),sellerRating 和 sellerReviewCount 是卖家的星级评分及评价数,returningBuyerRate 是卖家的回头客比例(0.52 = 52%),sold 是已售数量,warrantyHours 是从交付起计算的售后期(小时,0 表示无售后)。卖家没有评分或买家太少时,不返回 sellerRating、sellerReviewCount 和 returningBuyerRate。
按服务 ID(与服务列表中的 ID 相同)查询当前库存和可购买状态。对于市场商品,返回的 JSON 包含 subproducts:所有在售选项的数组,每项带有 subproductId、name、stock(该选项的展示库存),以及该选项自己的价格和下单限制:available、rate、min、max,按固定包销售的选项还有 packs。
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | inventory | 是 |
| service | 服务 ID(来自服务列表) | 是 |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=inventory" \
-d "service=23501"{
"service": 1,
"stock": 10000,
"available": true,
"rate": "0.5000",
"entityType": "smm",
"autoDelivery": true
}{
"service": 23501,
"stock": 42,
"available": true,
"rate": "25.0000",
"min": 1,
"max": 42,
"entityType": "product",
"autoDelivery": true,
"subproducts": [
{ "subproductId": "674a1f77bcf86cd799439011", "name": "1 Month", "stock": 42, "available": true, "rate": "25.0000", "min": 1, "max": 42 },
{ "subproductId": "674a1f77bcf86cd799439012", "name": "3 Months", "stock": 0, "available": false, "rate": "60.0000", "min": 1, "max": 0 },
{
"subproductId": "674a1f77bcf86cd799439013", "name": "Pack", "stock": 500, "available": true, "rate": "0.0190", "min": 100, "max": 100,
"packs": [
{ "quantity": 100, "price": "1.9000", "discountPercent": 5 },
{ "quantity": 500, "price": "9.0000", "discountPercent": 10 }
]
}
],
"warrantyHours": 24
}响应包含rate(单价,字符串格式与服务列表相同)、entityType(smm或product)和autoDelivery(true=自动发货,false=供应商手动处理)。对于产品服务,min和max匹配服务列表中的主要子产品行;如果该子产品无法满足您的加单需求,平台可能选择其他子产品并按其实时单价收费。subproducts数组列出所有活跃变体及其显示库存;SMM库存响应不包含subproducts。
每个子商品都有自己的 rate、min 和 max:这是传入该 subproductId 时 add 按此收取的单价和允许的数量范围,未扣除你账号的经销商折扣。对于按固定包销售的选项,packs 列出每个有货的包(quantity、总价 price、discountPercent),下单数量必须是其中之一;此时 rate、min 和 max 描述的是最小的包。
warrantyHours(仅商品)是该商品从交付起计算的售后期,单位为小时,与服务列表中的数值相同;0 表示无售后。
Place a standard order with link and quantity. Link: for SMM services (e.g. followers, likes) — required, use the URL to the content (e.g. Instagram post); for product orders (e.g. accounts) — optional, if empty the system uses your account email for delivery. For products with multiple options (Select Option on the website), pass subproductId (from action=inventory) to choose which option to order — otherwise the default option is used.
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | 是 |
| action | add | 是 |
| service | 服务 ID | 是 |
| link | 链接:SMM 订单(例如粉丝、点赞、评论)必填,填写内容的 URL 或链接(例如 Instagram 帖子链接)。商品订单(例如账号)可选,填写交付邮箱或备注;留空时系统使用你的账号邮箱。 | 否 |
| quantity | 下单数量 | 是 |
| subproductId | 仅商品:指定某个选项(网站上的 Select Option),而不是默认选项。使用 action=inventory 为该服务返回的 subproductId。可选;增长/SMM 服务不使用。 | 否 |
| coupon | 优惠码(来自 action=coupons 或店铺页面)。可选。在经销商折扣之后再抵扣,使用条件与网站下单相同;如果优惠码无法使用,则不会下单,错误信息会说明原因。 | 否 |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=add" \
-d "service=1" \
-d "link=https://instagram.com/username" \
-d "quantity=1000"
# Product with multiple options: pick the subproductId from action=inventory
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=add" \
-d "service=110469" \
-d "quantity=1" \
-d "subproductId=674a1f77bcf86cd799439012"
# With a coupon code from action=coupons
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=add" \
-d "service=110469" \
-d "quantity=10" \
-d "coupon=SAVE10"{
"order": 23501,
"entityType": "product",
"charge": "22.5000",
"couponDiscount": "2.5000",
"warrantyHours": 24
}charge 是从你余额中实际扣除的金额。只有使用了优惠码时才会返回 couponDiscount。warrantyHours(仅商品)是从交付起计算的售后期,单位为小时,0 表示无售后;action=status 会通过 warranty_expires_at 返回确切的到期时间。
获取订单状态。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | status |
| order | 订单ID |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=status" \
-d "order=23501"{
"status": "In progress",
"charge": "5.00",
"start_count": 1000,
"remains": 500,
"currency": "USD",
"autoDelivery": true
}对于产品订单(例如账户),当订单完全或部分交付时,响应中会包含一个"accounts"数组,其中包含已交付的账户凭据(每个账户一个字符串)。对于部分交付,仅返回目前已交付的账户。
autoDelivery:如果订单自动完成(例如 SMM、自动/库存产品),则为 true;如果供应商必须手动完成(可能需要一些时间),则为 false。
{
"status": "Completed",
"charge": "10.00",
"start_count": 5,
"remains": 0,
"currency": "USD",
"entityType": "product",
"autoDelivery": true,
"accounts": [
"user1:pass1",
"user2:pass2"
]
}已退款的订单返回 Canceled,部分退款的订单返回 Partial。只要有退款,响应中还会带有 "refunded",即退款金额(美元)。
部分商品(例如带 session 压缩包的 Telegram 账号)以 ZIP 文件交付,替代文本凭据或与之同时交付。此时响应中会包含 "files" 数组,每个文件对应一个交付项。用 action=order_file 下载文件。
{
"status": "Completed",
"charge": "12.00",
"start_count": 0,
"remains": 0,
"currency": "USD",
"entityType": "product",
"autoDelivery": false,
"files": [
{
"id": "66e6b2f0c3a1d2e4f5a6b7c8",
"name": "sessions-001.zip",
"size": 482113,
"uploaded_at": "2026-09-15T08:30:00.000Z"
}
]
}下载订单的某个交付文件(ZIP)。成功时响应体就是文件本身(Content-Type: application/zip);失败时是带 "error" 字段的 JSON。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | order_file |
| order | 订单ID |
| file | action=status 返回的 "files" 数组中的文件 id |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=order_file" \
-d "order=23501" \
-d "file=66e6b2f0c3a1d2e4f5a6b7c8" \
-o sessions-001.zip{
"error": "File not found"
}保存前先检查 Content-Type 响应头:application/zip 表示文件,application/json 表示出错。
取消一个或多个订单(兼容PerfectPanel的批量格式)。每个符合条件的订单将退款至您的余额。
以下所有条件必须为真。使用 allowcancel 检查资格,无需处理退款。
部分发货将按比例进行部分退款;已交付的账户予以保留。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | cancel |
| orders | 订单ID(以逗号分隔,最多100个ID) |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=cancel" \
-d "orders=23501,23502"[
{
"order": 23501,
"cancel": 1
},
{
"order": 23502,
"cancel": {
"error": "Incorrect order ID"
}
}
]检查一个或多个订单当前是否可取消(与取消相同的资格规则,但不处理退款)。在调用取消前使用此功能以避免请求失败。支持批量订单ID(以逗号分隔,最多100个)。
以下所有条件必须为真。使用 allowcancel 检查资格,无需处理退款。
当 allowcancel 为 1 时,响应中包含 refundAmount(取消操作将退还的金额)。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | allowcancel |
| orders | 订单ID(以逗号分隔,最多100个ID) |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=allowcancel" \
-d "orders=23501,23502"[
{
"order": 23501,
"allowcancel": 1,
"refundAmount": 5.00
},
{
"order": 23502,
"allowcancel": 0,
"error": "Early auto refund is not available for this order",
"reason": "BEFORE_MIN_WAIT",
"eligibleAfter": "2026-06-23T12:30:00.000Z"
}
]获取您当前的余额。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | balance |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=balance"{
"balance": "100.00",
"currency": "USD"
}按日期范围统计订单数量和总额,用于对账。统计口径与“您的订单”页面一致。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | orders_summary |
| date_from | 可选。起始日,YYYY-MM-DD,含当日。 |
| date_to | 可选。结束日,YYYY-MM-DD,含当日。 |
| tz | Optional. Your timezone, as minutes east of UTC (480 for UTC+8) or +08:00. Days start at midnight in this timezone. Default UTC. |
curl -X POST https://hstockplus.net/api/v2 \
-d "key=YOUR_API_KEY" \
-d "action=orders_summary" \
-d "date_from=2026-10-31" \
-d "date_to=2026-10-31" \
-d "tz=480"{
"date_from": "2026-10-30T16:00:00.000Z",
"date_to": "2026-10-31T16:00:00.000Z",
"orders": 126,
"refunded_orders": 3,
"gross": "412.5000",
"refunded": "6.2000",
"net": "406.3000",
"currency": "USD"
}date_from and date_to echo the range as UTC instants (date_to is exclusive). Only paid orders are counted; unpaid and failed orders are ignored. orders is the number of paid orders, gross is what you paid, refunded is what came back to you, net = gross - refunded. Call at most once every 2 seconds.
短信验证服务的专用端点。
短信订单有独立的订单 ID,请配合 sms_code、sms_status 和 sms_cancel 使用;status、cancel 和 allowcancel 只用于商品和 SMM 订单。
Action: sms_projects
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | sms_projects |
| country | 可选。按国家 ID 筛选(例如 'us'、'gb') |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 |
[
{
"project_id": "65f...",
"name": "OpenAI / ChatGPT",
"price": "0.5000",
"country_id": "us",
"country_title": "United States"
}
]Action: sms_countries
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | sms_countries |
| lang | 可选语言代码。请参阅上方“可选语言 (lang)”中的支持代码。 |
[
{
"country_code": "+1",
"country_name": "United States"
},
{
"country_code": "+44",
"country_name": "United Kingdom"
}
]Action: add_sms
| 参数 | 说明 | 必填 |
|---|---|---|
| key | 你的 API 密钥 | |
| action | add_sms | |
| project_id | 来自 sms_projects 的项目 ID | 是 |
| quantity | 号码数量(1-10) | 否(默认 1) |
| country | 国家:ISO 代码(例如 'us')或来自 sms_countries 的区号(例如 '+1') | 否 |
| phone | 要复用的手机号码 | 否 |
{
"orders": [
{
"order": 12345,
"phone": "4055123415",
"dial_code": "+1",
"phone_full": "+14055123415",
"country": "US",
"expires_at": "2026-01-01T12:15:00.000Z",
"status": "active"
}
]
}Action: sms_code
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | sms_code |
| order | 订单ID |
{
"status": "completed",
"code": "123456",
"sms_content": "Your verification code is 123456"
}
// OR
{
"status": "waiting",
"message": "Waiting for code"
}
// OR, once expires_at has passed without a code (call sms_cancel for a refund)
{
"status": "expired",
"message": "No code arrived before the number expired. Call action=sms_cancel for a refund."
}Action: sms_status
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | sms_status |
| order | 订单ID |
{
"status": "code_received",
"phone": "4055123415",
"dial_code": "+1",
"phone_full": "+14055123415",
"code": "123456",
"charge": "0.5000",
"currency": "USD",
"refunded": false,
"expires_at": "2026-01-01T12:15:00.000Z"
}
// status: phone_acquired | code_received | expired | releasedAction: sms_cancel
释放号码。如果没有收到验证码,费用会全额退回余额,号码过期后也一样。已收到验证码的订单不能取消。
| 参数 | 说明 |
|---|---|
| key | 你的 API 密钥 |
| action | sms_cancel |
| order | 来自 add_sms 的订单 ID |
{
"order": 12345,
"status": "cancelled",
"refunded": true,
"refund_amount": "0.5000",
"currency": "USD"
}
// OR
{
"error": "Verification code already received, cannot release"
}您可能会遇到的常见错误响应。
{"error": "Invalid API key"}{"error": "Invalid action"}{"error": "Service ID is required"}{"error": "Insufficient balance"}{"error": "Order not found"}{"error": "Service not found"}需要帮助?请通过以下方式联系我们: support@hstockplus.com