Skip to content

商品分类 ​

GET /categories

权限范围幂等operationId
catalog:read只读Catalog_categories

示例 ​

js
const res = await client.get("/categories");
http
GET /open/v1/categories HTTP/1.1
Host: api.sybb.pw
Authorization: SY-HMAC-SHA256 Credential=ak_…, Timestamp=1796035200, Nonce=…, Signature=…

响应 200:

json
{
  "items": [
    {
      "categoryId": "cat_1Yrxlo5gHYwz6FCJlUWBjrD",
      "parentId": "cat_11zIbieRYMZrlCbiDviPxJj",
      "name": "周末双排体验券",
      "iconUrl": "https://example.com/icon.png",
      "enabled": true,
      "sort": 1,
      "standardServiceCount": 1
    }
  ]
}

响应 ​

CategoryView ​

字段类型必填说明
categoryIdstring商品分类 ID(cat_…)
parentIdstring商品分类 ID(cat_…)
namestring名称
iconUrlstring图标 URL
enabledboolean是是否启用
sortinteger排序(小的在前)
standardServiceCountinteger标准服务数量(如时长、局数)

错误 ​

签名、权限、限流等通用错误见错误处理。

ByteForge · 神运开放平台接口地址 https://api.sybb.pw/open/v1