更新 — 商品
既存の製品、価格、出版データを変更します。
PATCH
/api/v1/products/{product_id}cURLリクエスト
curl --disable --globoff --fail-with-body --silent --show-error \
--proto '=https' --connect-timeout 5 --max-time 30 \
--request PATCH \
--url https://shop.onshopently.com/api/v1/products/example \
--header 'Authorization: Bearer EXAMPLE_ACCESS_TOKEN' \
--header 'Idempotency-Key: example-update_product_api_v1_products__product_id__patch' \
--header 'Content-Type: application/json' \
--data-raw '{"expected_version":1,"sku":"example"}'
レスポンス
{
"data": {
"deleted": false,
"id": "example",
"version": 1
},
"meta": {
"request_id": "example"
}
}
必要な権限
バリエーションも変更する場合
variant_value_ids フィールドを送信する場合は、キーに次の権限を追加してください。
variants_enabled フィールドを送信する場合は、キーに次の権限を追加してください。