...
1. Inventory Quantity
1) Purpose
특정 상품의 Product의 인벤토리의 가용성을 확인하기 위하여 사용하는 API입니다.
가용성을 확인하면 해당 인벤토리를 구매 가능 여부를 판단할 수 있습니다.
...
2. API spec
1) Request
Endpoint | product environment: https://prod.ax-cloud.com/v1/channel/inventory/day-ticket/{product_idcode} |
---|---|
Method | GET |
Description | 특정 Product의 Inventory를 조회합니다. |
Content-Type | application/json |
Headers > Authorization | Token {api_key} |
Headers > Channel | Code {channel_code} |
...
Name | Required | Type | Description |
---|---|---|---|
product_idcode | O | StringUUID | Product ID(UUID) |
3) Query Parameter
Name | Required | Type | Description |
---|---|---|---|
page | X | Integer | Page number(default : 1) |
page_size | X | Integer | Size per page(default : 25) |
...
Name | Type | Description | |||||
---|---|---|---|---|---|---|---|
status_code | Integer | 정상 처리 시 200 | data|||||
option_codes | Object | ||||||
{option_code} | List[Object] | 인벤토리 리스트 | id | Integer | 인벤토리 아이디상품의 옵션 식별자 | ||
inventory_code | String | 상품의 인벤토리 식별자 | |||||
date | Date | 날짜 | |||||
max_quantity | Integer | 최초 생성 재고 | |||||
remain_quantity | Integer | 남은 재고 | |||||
ordered_quantity | Integer | 주문 갯수 | depth_combination_id | String | 인벤토리 연관된 옵션 아이디 |
4) Response Example
Expand | |||||
---|---|---|---|---|---|
| |||||
|
5) Error Spec
Expand | ||
---|---|---|
| ||
|
...
Code Block |
---|
curl -X 'POST' \ 'https://prod.ax-cloud.com/v1/channel/inventory/day-ticket/16ecf4685-ca60-4a7d-843c-479329ca8789' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -H 'Authorization: Token api_key_secret' \ -H 'Channel: Code code_secret' -d '{ "status_code": 200, "data"option_codes": { "1e0bd91f-989a-45e7-8e1c-4fe2d4231ae5": [ { "idinventory_code": 1"d50a6594-3457-4e87-afe1-435ca13b8cdd", "date": "2023-03-01", "max_quantity": 25, "remain_quantity": 15, "ordered_quantity": 10, "depth_combination_id": 15}, }, { { "idinventory_code": 2,"374bf54a-d7c1-4ad3-a95a-32aa3e7212ae", "date": "2023-03-08", "max_quantity": 25, "remain_quantity": 5, "ordered_quantity": 20, "depth_combination_id": 15}, }, { { "idinventory_code": 3"5e77bcf2-9026-4263-847b-a8a4a84b5613", "date": "2023-03-15", "max_quantity": 25, "remain_quantity": 11, "ordered_quantity": 14, "depth_combination_id": 15} ] } ]} }' |
...