AccsmarketX
ZH
登录注册

开发者 API

在您的脚本、机器人或商店中查询库存、价格和订单并购买账号。所有响应均为 JSON。

快速开始

基础地址

https://api.accsmarketx.com/api/v1/developer

身份验证

在每个请求的 X-API-Key 请求头中发送 API 密钥。密钥可在账户的“开发者 API”中创建。

请妥善保管密钥:不要放入公开代码库,也不要用于在浏览器中运行的代码。

curl -X GET "https://api.accsmarketx.com/api/v1/developer/balance" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

请求频率限制

每组接口每个地址每分钟最多 60 次请求:余额、数据(分类、商品、订单)和购买。超出将返回 429 Too Many Requests。

GET

/api/v1/developer/balance

钱包余额

您当前的钱包余额。

curl -X GET "https://api.accsmarketx.com/api/v1/developer/balance" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "balance": 150.75
  },
  "message": "Balance retrieved successfully",
  "success": true
}
GET

/api/v1/developer/categories

分类

全部启用的分类,含名称、slug 和图标,按商店顺序排列。

curl -X GET "https://api.accsmarketx.com/api/v1/developer/categories" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": [
    {
      "name": "Telegram",
      "slug": "telegram",
      "iconUrl": "https://files.example.com/icons/demo.webp",
      "order": 1
    },
    {
      "name": "Gmail / Google",
      "slug": "gmail",
      "iconUrl": "https://files.example.com/icons/demo.webp",
      "order": 2
    }
  ],
  "message": "Categories retrieved successfully",
  "success": true
}
GET

/api/v1/developer/products

全部商品

全部分类的在售商品,每页 20 个。pricePerProduct 已含商品折扣,stock 为当前可购数量。

参数类型必填说明
pageNumber, 在地址中可选页码,从 1 开始(默认 1)。
categoryString, 在地址中可选仅此分类,按 slug(例如 gmail)。
searchString, 在地址中可选仅标题包含此文本的商品,最多 100 个字符。
curl -X GET "https://api.accsmarketx.com/api/v1/developer/products?page=1" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "products": [
      {
        "id": "6a28efbf223003dee8cf6c97",
        "batchId": 4892152,
        "service": "telegram",
        "pricePerProduct": 2.50,
        "discount": 0,
        "warrantyHours": 24,
        "accountFormat": "Phone:Session",
        "accountAge": "2022",
        "countryOfOrigin": "USA",
        "preorderEnabled": true,
        "stock": 42,
        "seller": "Demo Store",
        "content": {
          "title": "Telegram Aged Accounts",
          "oneLinerDescription": "High quality TData & Session+Json Telegram accounts.",
          "description": "Full uncompressed description text..."
        }
      }
    ],
    "pagination": { "page": 1, "limit": 20, "totalPages": 1, "totalItems": 1 }
  },
  "message": "Products retrieved successfully",
  "success": true
}
GET

/api/v1/developer/products/category

单个分类的商品

单个分类的在售商品,每页 20 个。也可通过 /products/category/{slug} 获取同一列表。

参数类型必填说明
categoryString, 在地址中可选分类 slug,例如 gmail、telegram 或 software。
pageNumber, 在地址中可选页码,从 1 开始(默认 1)。
curl -X GET "https://api.accsmarketx.com/api/v1/developer/products/category?category=gmail&page=1" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "products": [
      {
        "id": "6a28efbf223003dee8cf6c97",
        "batchId": 3731693,
        "service": "gmail",
        "pricePerProduct": 1.20,
        "stock": 150,
        "seller": "Demo Store",
        "content": {
          "title": "Gmail PVA 2023 Aged Accounts",
          "description": "Full uncompressed description..."
        }
      }
    ],
    "pagination": { "page": 1, "limit": 20, "totalPages": 1, "totalItems": 1 }
  },
  "message": "Products retrieved successfully",
  "success": true
}
GET

/api/v1/developer/products?batchID=

单个商品

按编号获取单个商品及完整描述。也可通过 /products/{batchID} 获取。

参数类型必填说明
batchIDNumber, 在地址中必填商品编号,例如 3731693。
curl -X GET "https://api.accsmarketx.com/api/v1/developer/products?batchID=3731693" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "id": "6a28efbf223003dee8cf6c97",
    "batchId": 3731693,
    "service": "gmail",
    "pricePerProduct": 1.20,
    "discount": 0,
    "warrantyHours": 48,
    "accountFormat": "Email:Password:RecoveryEmail",
    "accountAge": "6+ months",
    "countryOfOrigin": "Mixed",
    "stock": 150,
    "seller": "Demo Store",
    "content": {
      "title": "Gmail PVA 2023 Aged Accounts",
      "oneLinerDescription": "High trust Gmail accounts with recovery email.",
      "description": "Full uncompressed HTML/text description...",
      "features": "• 2FA Included\\n• Recovery Email set",
      "accordionContent": [
        { "title": "How to use", "description": "Download portable browser..." }
      ]
    }
  },
  "message": "Product retrieved successfully",
  "success": true
}
POST

/api/v1/developer/buy

下单

一步完成:从钱包扣款、从库存取出账号并创建订单。返回 201 Created 和订单;通过“单个订单”获取账号。

参数类型必填说明
batch_idString, 在 JSON 请求体中必填商品响应中的 id(不是编号)。
total_productsNumber, 在 JSON 请求体中必填账号数量,1 至 100000。
coupon_codeString, 在 JSON 请求体中可选优惠码(如有)。
curl -X POST "https://api.accsmarketx.com/api/v1/developer/buy" \
  -H "X-API-Key: YOUR_API_KEY_HERE" \
  -H "Content-Type: application/json" \
  -d '{
    "batch_id": "6a28efbf223003dee8cf6c97",
    "total_products": 1
  }'

响应示例

{
  "success": true,
  "message": "Order placed successfully",
  "order": {
    "batch_id": "6a28efbf223003dee8cf6c97",
    "total_products": 1,
    "total_price": 2.5,
    "price_per_product": 2.5,
    "orderId": "58AE95EE",
    "coupon_info": null,
    "createdAt": "2026-08-04T16:00:00.000Z",
    "updatedAt": "2026-08-04T16:00:00.000Z"
  }
}
GET

/api/v1/developer/orders

订单历史

您的订单,最新的在前,每页 10 个。

参数类型必填说明
pageNumber, 在地址中可选页码,从 1 开始(默认 1)。
startDateString, 在地址中可选仅此日期起的订单,格式 YYYY-MM-DD(UTC)。
endDateString, 在地址中可选仅此日期前的订单,格式 YYYY-MM-DD(UTC)。
curl -X GET "https://api.accsmarketx.com/api/v1/developer/orders?page=1" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "orders": [
      {
        "orderId": "58AE95EE",
        "total_products": 1,
        "total_price": 2.50,
        "price_per_product": 2.50,
        "createdAt": "2026-08-04T16:00:00.000Z"
      }
    ],
    "pagination": { "page": 1, "limit": 10, "totalPages": 1, "totalItems": 1 }
  },
  "message": "Orders retrieved successfully",
  "success": true
}
GET

/api/v1/developer/orders?order=

单个订单

按订单号获取您的单个订单及账号。

参数类型必填说明
orderString, 在地址中必填订单号,例如 58AE95EE。
curl -X GET "https://api.accsmarketx.com/api/v1/developer/orders?order=58AE95EE" \
  -H "X-API-Key: YOUR_API_KEY_HERE"

响应示例

{
  "statusCode": 200,
  "data": {
    "orderId": "58AE95EE",
    "batch_id": { "batchId": 3731693, "content": { "title": "Demo listing", "oneLinerDescription": "Made-up example." } },
    "total_products": 1,
    "total_price": 2.50,
    "price_per_product": 2.50,
    "products": [
      "username:password:[email protected]"
    ],
    "createdAt": "2026-08-04T16:00:00.000Z"
  },
  "message": "Order retrieved successfully",
  "success": true
}

错误和状态码

出错时会返回状态码和 JSON,其中 message 说明错误原因。只有 429(请求过多)返回纯文本。

200 OK请求成功。
201 Created订单已创建。
400 Bad Request缺少或错误的参数、库存或钱包余额不足,或优惠码不可用。
401 Unauthorized缺少 X-API-Key 请求头、密钥无效或账户已被封禁。
403 Forbidden下单功能维护中暂停,或商品卖家已被暂停。
404 Not Found商品或订单不存在,或订单不属于您。
429 Too Many Requests您的地址对该组接口每分钟请求超过 60 次。
500 Server Error我们这边出错了。请重试,如仍有问题请联系客服。