Get Taste
Description
取得商品的口味或加值。
Resource
GET /v1/product/taste
Authorization
採用 OAuth 2.0 Bearer Token,詳細使用流程請參考 Auth Login。
Query Parameters
| Name | Type | Description |
|---|---|---|
| product_id | string | 商品代碼 |
| store_id | string | 門市代碼 (optional) |
| language | string |
語系 (optional)ALLOWED VALUES:
|
Response Body Parameters
| Name | Type | Description |
|---|---|---|
| tastes | Taste | 口味/加值列表 |
Response Body Parameters - Taste
| Name | Type | Description |
|---|---|---|
| id | int | 口味/加值編號 |
| title | string | 口味/加值名稱 |
| is_mutually_exclusive | bool | 是否互斥 |
| kind | string | 口味/加值種類 |
| is_required | bool | 是否必填 |
| default | Item[] | 預設加值項目 |
| items | Item | 口味/加值項目 |
| max_quantity | integer | 最大加值數量 |
| position | integer | 加值排序 |
Response Body Parameters - Item
| Name | Type | Description |
|---|---|---|
| id | int | 口味/加值項目編號 |
| title | string | 口味/加值項目名稱 |
| price | int | 口味/加值項目價格 |
| size_child_product_id | string | 尺寸子商品編號 (optional) |
| image_url | string | 口味/加值項目圖檔URL |
Response Body Parameters - Default
| Name | Type | Description |
|---|---|---|
| taste_sno | int | 口味/加值項目編號 |
| name | string | 口味/加值項目名稱 |
| price | int | 口味/加值項目價格 |
| size_price | money | 尺寸子商品價格 |
| image_url | string | 口味/加值項目圖檔URL |
Response
{
"tastes": [
{
"id": 1,
"title": "外帶",
"is_mutually_exclusive": true,
"is_required": false,
"kind": "0",
"items": [
{
"id": 1,
"title": "內用",
"price": 0,
"image_url": ""
},
{
"id": 2,
"title": "外帶",
"price": -5,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 0
},
{
"id": 3,
"title": "飯",
"is_mutually_exclusive": false,
"is_required": false,
"kind": "0",
"items": [
{
"id": 1,
"title": "不加辣蘿蔔",
"price": 0,
"image_url": "https://portal-dev.wixtar.com/kiosk/apptest/public/taste01/1542435165.webp"
},
{
"id": 2,
"title": "不加玉米",
"price": 0,
"image_url": ""
},
{
"id": 3,
"title": "+滷汁",
"price": 0,
"image_url": ""
},
{
"id": 4,
"title": "不要飯",
"price": 0,
"image_url": ""
},
{
"id": 5,
"title": "飯少",
"price": 0,
"image_url": ""
},
{
"id": 6,
"title": "飯多",
"price": 0,
"image_url": ""
},
{
"id": 7,
"title": "加購雞滷醬",
"price": 10,
"image_url": ""
}
],
"default": {
"taste_sno": 7,
"name": "加購雞滷醬",
"price": 10,
"image_url": "",
"size_price": 0.0
},
"max_quantity": null,
"position": 1
},
{
"id": 4,
"title": "切塊",
"is_mutually_exclusive": false,
"is_required": false,
"kind": "0",
"items": [
{
"id": 1,
"title": "要切",
"price": 0,
"image_url": ""
},
{
"id": 2,
"title": "切小塊",
"price": 0,
"image_url": ""
},
{
"id": 3,
"title": "主食裝一起",
"price": 0,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 2
},
{
"id": 5,
"title": "環保餐具",
"is_mutually_exclusive": false,
"is_required": false,
"kind": "0",
"items": [
{
"id": 1,
"title": "自備餐具",
"price": -5,
"image_url": ""
},
{
"id": 2,
"title": "環保餐具-主食分開裝",
"price": 0,
"image_url": ""
},
{
"id": 3,
"title": "環保餐具-主食放一起",
"price": 0,
"image_url": ""
},
{
"id": 4,
"title": "非常環保",
"price": -50,
"image_url": ""
},
{
"id": 5,
"title": "不環保",
"price": 10,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 3
},
{
"id": 7,
"title": "炸物",
"is_mutually_exclusive": false,
"is_required": true,
"kind": "0",
"items": [
{
"id": 3,
"title": "瘦一點",
"price": 0,
"image_url": ""
},
{
"id": 4,
"title": "肥一點",
"price": 0,
"image_url": ""
},
{
"id": 5,
"title": "醬多",
"price": 0,
"image_url": ""
}
],
"default": {
"taste_sno": 3,
"name": "瘦一點",
"price": 0,
"image_url": "",
"size_price": 0.0
},
"max_quantity": null,
"position": 4
},
{
"id": 8,
"title": "燙青菜",
"is_mutually_exclusive": false,
"is_required": false,
"kind": "2",
"items": [
{
"id": 1,
"title": "不加油蔥",
"price": 0,
"image_url": ""
},
{
"id": 2,
"title": "不加油膏",
"price": 0,
"image_url": ""
},
{
"id": 3,
"title": "全不加",
"price": 0,
"image_url": ""
},
{
"id": 4,
"title": "油膏多",
"price": 0,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 5
},
{
"id": 13,
"title": "超值加購-白飯",
"is_mutually_exclusive": false,
"is_required": false,
"kind": "0",
"items": [
{
"id": 1,
"title": "白飯",
"price": 10,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 6
},
{
"id": 23,
"title": "小菜",
"is_mutually_exclusive": true,
"is_required": true,
"kind": "0",
"items": [
{
"id": 2,
"title": "不加油膏",
"price": 0,
"image_url": ""
},
{
"id": 3,
"title": "全不加",
"price": 0,
"image_url": ""
},
{
"id": 4,
"title": "油膏多",
"price": 0,
"image_url": ""
},
{
"id": 5,
"title": "不加柴魚",
"price": 0,
"image_url": ""
}
],
"default": {},
"max_quantity": null,
"position": 7
}
]
}