Get Product Tickets
Description
取得商品券。
Resource
GET /v1/ticket/product
Authorization
採用 OAuth 2.0 Bearer Token,詳細使用流程請參考 Auth Login。
Query Parameters
| Name | Type | Description |
|---|---|---|
| category_id | string | 商品類別編號 (optional) |
Request
GET /v1/ticket/product?category_id=12
Response Body Parameters
| Name | Type | Description |
|---|---|---|
| tickets | Ticket[] | 票券列表 |
Response Body Parameters - Ticket
| Name | Type | Description |
|---|---|---|
| product_id | string | 商品編號 |
| title | string | 商品名稱 |
| memo | string | 商品備註 |
| spec | string | 規格 |
| unit | string | 單位 |
| spend_points | integer | 兌換所需點數 |
| origin | string | 產地 |
| img | string | 圖檔URL |
| description | string | 描述 |
| id | string | 票券編號 |
| start_date | string | 有效起日 EXAMPLE "2020-01-01 12:00:00" |
| end_date | string | 有效迄日 EXAMPLE "2020-01-01 12:00:00" |
| category_ids | list[string] | 類別編號列表 |
| ticket_kind | string | 票劵種類 ALLOWED VALUES:
|
Response ticket_kind
| kind_type | description |
|---|---|
| GIFT_VOUCHER | 禮券 |
| SALE_EVENT_COUPON | 抵用券 |
| ENTRANCE_TICKET | 入場券 |
| DISCOUNT_COUPON | 折扣券 |
| CASH_COUPON | 折價券 |
| PRODUCT_SPECIFIC_COUPONS | 商品券 |
Response
{
"tickets": [
{
"product_id": "UC00000011",
"title": "椒鹽雞塊(單點)",
"memo": "",
"spec": "300G",
"unit": "PCS",
"spend_points": 0,
"origin": "台灣",
"img": "http://40.83.96.208:8080/kiosk/app/public/product00/5839-1-1550816490_s.png",
"description": null,
"id": "200",
"start_date": "2021-08-01 12:00:00",
"end_date": "2021-08-31 12:00:00",
"category_ids": [
"24958"
],
"ticket_kind": "PRODUCT_SPECIFIC_COUPONS"
}
]
}