查詢單一商品
查詢單一商品
依 id 查詢單一商品。若該 id 不存在、屬於其他租戶,或指向的是組合商品,一律回傳 404 not_found,這幾種情況無法從回應內容區分。
Authentication
X-Signaturestring
每個 /v1 請求都必須帶 `X-Client-Id`、`X-Timestamp`、`X-Nonce` 與 `X-Signature` 四個標頭。`X-Signature` 是以 client secret 對 canonical string 做 HMAC-SHA256 後的 Base64。
canonical string 的組成、可複製的簽章範例與 401 排查步驟,請參閱[「驗證與簽章」](/authentication)。
Path parameters
id
要查詢的商品序號。不存在、屬於其他租戶,或指向組合商品時,一律回傳 404 not_found。
Response
OK
id
商品序號。
outerSysCode
ERP 端的商品代碼。
name
商品名稱。
status
商品狀態,共三種:Active(上架)、Inactive(下架,前台完全不會陳列)、InactiveVisible(下架-顯示,前台仍會陳列,但標示為不可購買)。狀態值只能在後台維護,本 API 目前不提供寫入;透過本 API 建立的商品一律為 Active。
productCategoryId
商品目前所屬的分類 id,方便 ERP 核對自己設定的值是否生效。
Errors
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
500
Internal Server Error