catIdstring
1688 platform category ID.
https://api.sandbase.ai/v1/api/1688/category/infoGet a 1688 category and its child categories by category ID, or the root categories when no ID is given.
出力はここに表示されます
入力を完了してから[実行]をクリックしてください。
Returns a 1688 category and its child categories. Send a catId to get that category with its children, or send no input to get the root categories.
catId and walking down through children[].id.name and name_en for a catalog or translation table.children[].has_children to decide which categories need another call to reach leaf categories.curl -X POST "https://api.sandbase.ai/v1/api/1688/category/info" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
catId | string | No | 1688 platform category ID. |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"children": [
{
"has_children": true,
"id": "130823000",
"level": 0,
"name": "成人用品",
"name_en": "Adult Products"
}
],
"id": "",
"level": null,
"name": "",
"name_en": ""
}
| Field | Meaning |
|---|---|
children[] | List of child categories. With no catId in the request, this list holds the root categories. |
children[].id | Category ID as a string. Use it as catId in the next call. |
children[].name | Category name in Chinese. |
children[].name_en | Category name in English. |
children[].has_children | true when the category has child categories below it. Use it to decide whether to go deeper. |
children[].level | Depth number of the child category. Root categories show 0. |
id / name / name_en | ID and names of the requested category. These are empty strings when no catId is sent. |
level | Depth of the requested category. It is null when no catId is sent. |
catId out to get the root categories. The top-level id, name and name_en are then empty and level is null.id values are strings, for example "130823000" and "54". Pass them back unchanged as catId.$0.014286 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
開発を始める
統一認証と使用状況の追跡を備えたプラットフォームAPIエンドポイントです。
curl -X POST "https://api.sandbase.ai/v1/api/1688/category/info" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'SandBaseのAPIキーをサーバー環境に設定してください。リクエストはBearer認証を使用します。
export SANDBASE_API_KEY="YOUR_API_KEY"キーはサーバー側で管理してください。ブラウザコードに公開しないでください。
catIdstring1688 platform category ID.
このAPIの保存済みサンプルレスポンスです。表示時にライブリクエストは行われません。
保存済みレスポンスはまだ公開されていません。PlaygroundでAPIを実行し、レスポンスを確認してください。
さらに探索
| API | 価格 | レスポンス |
|---|---|---|
1688 Category Infoこの API 1688 | $0.014286 / 回 | JSON |
1688 | $0.014286 / 回 | JSON |
1688 | $0.014286 / 回 | JSON |
1688 | $0.014286 / 回 | JSON |
1688 | $0.014286 / 回 | JSON |
1688 | $0.014286 / 回 | JSON |
質問
Authorization ヘッダー(Bearer)に SandBase API key を指定し、パラメータを JSON ボディで送信して https://api.sandbase.ai/v1/api/1688/category/info に POST リクエストを送ります。このページの Playground で、コードを書かずに試すこともできます。
1回あたり $0.014286、SandBase 残高から課金されます。課金対象はご利用分のみで、サブスクリプションはありません。
必須パラメータはありません。 任意: catId (string)。 このページの Parameters テーブルと Playground に、すべてのフィールドが一覧表示されています。
同じ HTTP リクエスト内で返される JSON レスポンスです(同期)。 このページの README にサンプルレスポンスがあります。
いいえ。1688 Category Info は SandBase 経由で動作するため、SandBase の API key 1つでこのエンドポイントと、カタログ内の他のすべての API とモデルを利用できます。1688 の API アクセスを別途申請する必要はありません。