list_channels
Retrieve the enabled sales channels in your Shopline store, covering online store, POS, and social platforms. Verify channel configuration or prepare for multi-channel performance analysis.
Instructions
取得商店所有銷售渠道清單。
【用途】 查看商店目前開啟的銷售渠道,例如線上商店、POS、 Facebook、Instagram 等。適合了解多渠道銷售佈局, 或做渠道業績分析前的渠道資料確認。
注意:此端點在部分 token 權限下可能回傳 403, 渠道資訊亦可從訂單的 channel.created_by_channel_name 欄位取得。
【呼叫的 Shopline API】
GET /v1/channels?platform={platform}
【回傳結構】 dict 含 total, platforms_queried[], platforms_failed[], channels[]。 每個 channel 包含 id, name, channel_type, platform, enabled, created_at 等。 platforms_failed 非空代表部分平台查詢失敗,此時 channels 不完整 (勿將空結果直接解讀為「沒有渠道」)。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| platform | No | 平台篩選,如 shopline / shopline_pos。不填則自動查詢常見平台並合併結果 |