API Hop

文档目录

API Hop 文档

Walmart 接口参考

搜索 Walmart 商品,查询商品详情、卖家报价和评论。

并发上限

AI 与 Data 分别共享账户级并发槽位,默认 5 AI / 2 Data,订阅套餐可调整上限。接口单独配置仍受分类总上限约束。达到任一上限返回 HTTP 429;异步任务执行结束前占用槽位。

GET /v1/walmart/search
默认并发上限: 2
GET /v1/walmart/product
默认并发上限: 2
GET /v1/walmart/product/sellers
默认并发上限: 2
GET /v1/walmart/reviews
默认并发上限: 2

搜索 Walmart 商品,查询商品详情、卖家报价和评论。

认证与计费

默认每次成功请求 $0.0003(300 credits)。 使用 API Hop API Key。可用性取决于已启用网关和密钥权限。每次成功请求的价格以当前目录和账户显示为准,账户专属价格优先。成功的空结果也计费,失败请求释放预占额度。超时为 60 秒,不自动重试或翻页,结算失败不会重复调用上游。

http
Authorization: Bearer YOUR_API_KEY

Walmart: 搜索商品

GET https://api.apihop.ai/v1/walmart/search

请求参数

字段类型约束示例
querystring搜索词; query: optionalcoffee
pageinteger页码(从 1 开始); page: optional; min: 1; max: 1001
devicestring设备; device: optional; desktop, mobile, tabletdesktop
zero_traceboolean不归档响应产物; zero_trace: optionaltrue
store_idstring平台原生筛选条件 (store_id); store_id: optional; ^[0-9]{1,10}$-
walmart_domainstring平台区域域名 (walmart_domain); walmart_domain: optional; walmart.com, walmart.com.mxwalmart.com
sortstring平台原生排序 (sort); sort: optional; price_low, price_high, best_seller, best_match, rating_high, newprice_low
soft_sortboolean平台原生筛选条件 (soft_sort); soft_sort: optionaltrue
cat_idstring分类标识 (cat_id); cat_id: optional; ^[0-9]+(?:_[0-9]+)*$-
facetstring平台原生筛选条件 (facet); facet: optional; UTF-8 bytes: 4096-
min_pricenumber最低价格 (min_price); min_price: optional; min: 0; max: 10000000000
max_pricenumber最高价格 (max_price); max_price: optional; min: 0; max: 10000000000
spellingboolean平台原生筛选条件 (spelling); spelling: optionaltrue
nd_enboolean平台原生筛选条件 (nd_en); nd_en: optionaltrue
include_filtersboolean平台原生筛选条件 (include_filters); include_filters: optionaltrue

校验规则

仅接受查询参数,不接受请求体。拒绝未知、重复、空值或无效参数。仅支持 JSON 响应,不自动翻页或重试。下列规则中 AND 表示同时提供,OR 表示任一,XOR 表示二选一,NOT 表示不能提供,=> 表示需要。

  • GET query only; body = null; response = JSON; html, output, json_restrictor, no_cache: NOT supported
  • string: UTF-8 bytes <= maxLength (default 8192); boolean = true OR false; integer: safe integer
  • language: /^[A-Za-z]{2,3}(?:[-_][A-Za-z]{2,4})?$/
  • min_price <= max_price
  • query OR cat_id: required

示例

bash
curl --get "https://api.apihop.ai/v1/walmart/search" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "query=coffee"

Walmart: 查询商品详情

GET https://api.apihop.ai/v1/walmart/product

请求参数

字段类型约束示例
idstring从搜索结果复制的商品或卖家标识 (id); id: REQUIRED510561525
devicestring设备; device: optional; desktop, mobile, tabletdesktop
zero_traceboolean不归档响应产物; zero_trace: optionaltrue
store_idstring平台原生筛选条件 (store_id); store_id: optional; ^[0-9]{1,10}$-

校验规则

仅接受查询参数,不接受请求体。拒绝未知、重复、空值或无效参数。仅支持 JSON 响应,不自动翻页或重试。下列规则中 AND 表示同时提供,OR 表示任一,XOR 表示二选一,NOT 表示不能提供,=> 表示需要。

  • GET query only; body = null; response = JSON; html, output, json_restrictor, no_cache: NOT supported
  • string: UTF-8 bytes <= maxLength (default 8192); boolean = true OR false; integer: safe integer
  • language: /^[A-Za-z]{2,3}(?:[-_][A-Za-z]{2,4})?$/
  • id: /^[0-9]{1,30}$/

示例

bash
curl --get "https://api.apihop.ai/v1/walmart/product" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "id=510561525"

Walmart: 查询卖家报价

GET https://api.apihop.ai/v1/walmart/product/sellers

请求参数

字段类型约束示例
idstring从搜索结果复制的商品或卖家标识 (id); id: REQUIRED10543894
devicestring设备; device: optional; desktop, mobile, tabletdesktop
zero_traceboolean不归档响应产物; zero_trace: optionaltrue
store_idstring平台原生筛选条件 (store_id); store_id: REQUIRED; ^[1-9][0-9]{0,9}$100

校验规则

仅接受查询参数,不接受请求体。拒绝未知、重复、空值或无效参数。仅支持 JSON 响应,不自动翻页或重试。下列规则中 AND 表示同时提供,OR 表示任一,XOR 表示二选一,NOT 表示不能提供,=> 表示需要。

  • GET query only; body = null; response = JSON; html, output, json_restrictor, no_cache: NOT supported
  • string: UTF-8 bytes <= maxLength (default 8192); boolean = true OR false; integer: safe integer
  • language: /^[A-Za-z]{2,3}(?:[-_][A-Za-z]{2,4})?$/
  • id: /^[0-9]{1,30}$/

示例

bash
curl --get "https://api.apihop.ai/v1/walmart/product/sellers" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "id=10543894" \
  --data-urlencode "store_id=100"

Walmart: 查询评论

GET https://api.apihop.ai/v1/walmart/reviews

请求参数

字段类型约束示例
idstring从搜索结果复制的商品或卖家标识 (id); id: REQUIRED510561525
pageinteger页码(从 1 开始); page: optional; min: 1; max: 1001
devicestring设备; device: optional; desktop, mobile, tabletdesktop
zero_traceboolean不归档响应产物; zero_trace: optionaltrue
ratinginteger星级(逗号分隔); rating: optional; min: 1; max: 51
sortstring平台原生排序 (sort); sort: optional; relevancy, helpful, submission-desc, submission-asc, rating-desc, rating-ascrelevancy

校验规则

仅接受查询参数,不接受请求体。拒绝未知、重复、空值或无效参数。仅支持 JSON 响应,不自动翻页或重试。下列规则中 AND 表示同时提供,OR 表示任一,XOR 表示二选一,NOT 表示不能提供,=> 表示需要。

  • GET query only; body = null; response = JSON; html, output, json_restrictor, no_cache: NOT supported
  • string: UTF-8 bytes <= maxLength (default 8192); boolean = true OR false; integer: safe integer
  • language: /^[A-Za-z]{2,3}(?:[-_][A-Za-z]{2,4})?$/
  • id: /^[0-9]{1,30}$/

示例

bash
curl --get "https://api.apihop.ai/v1/walmart/reviews" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "id=510561525"

响应与错误

保留原生 JSON 响应和数字精度。下方仅为空成功结果示例,不是真实调用。HTTP 400 表示输入无效;401 需要认证;402 余额不足;403 不可用或无权限;405 方法不支持;429 限流;5xx 服务或上游故障。请保留 X-Request-Id 以便排查。

json
{
  "success": true,
  "request_id": "example-request",
  "data": {
    "format": "json",
    "content": {
      "results": []
    }
  }
}