Query Real-Time Inventory
This interface is the kiosk-specific version.
Query inventory information. Third-party platforms can call this interface to query the stock quantity of all channels from the open platform, enabling timely management of inventory status.
Interface Information
- Endpoint:
https://www.colorpark.cn/api/Printer/getChannelStocks - Method: POST
Request Parameters
| Parameter | Example Value | Data Type | Required | Description |
|---|---|---|---|---|
| printer_id | 500001 | string | Yes | The unique ID assigned to the printer; each printer is assigned a different number. |
| once | 8305 | string | Yes | A random value used when generating the encrypted signature (nonce). |
| time | 1646790335 | string | Yes | The timestamp used when generating the encrypted signature. |
| sign | 9ce3ce7a3fccaf3d7715bd7e9bb1dc1c | string | Yes | The generated signature. For the generation method, refer to the "Generate Signature" section under Underlying Methods [Basic Support]. |
| channel | 1 | string | No | 1: channel 1; 2: channel 2; 3: channel 3; 4: channel 4. If omitted, all channels' quantities are queried. |
Response
| Parameter | Data Type | Example Value | Description |
|---|---|---|---|
| code | string | 0 | Result status code. 0 on success, 1 on failure. |
| msg | string | 获取成功 (retrieved successfully) | Result description, e.g. "retrieved successfully". |
| data | array of objects | [{"channel":1,"stock_quantity":10},{"channel":2,"stock_quantity":20}] |
Array of channel-inventory objects. |
| channel | string | 1 | Channel index. |
| stock_quantity | string | 20 | Stock quantity. |
If a device encounters an unresolved issue during debugging, contact the cloud-printing responsible person for troubleshooting. Phone: 137-5177-4454 (WeChat same number); Email: info@ColorPark.cn
© Ruifengcai (瑞丰彩) — UV cloud-printing service provider with deep hardware–software integration