客位数据接口 ¶
客位列表 ¶
获取当前商户客位列表
请求
基本 | |
---|---|
HTTP URL | https://macromap.cxkjedu.com/api/open/seats |
HTTP Method | GET |
请求头
名称 | 类型 | 必填 | 描述 |
---|---|---|---|
Content-Type | string | 是 | 固定值:"application/json; charset=utf-8" |
open-token | string | 是 | app_api_token 示例值:"d13fc57d46bac217" 了解更多:获取访问凭证 api_token |
查询参数
该请求无请求参数
请求体
该请求无请求体
请求体示例
$ curl --location --request GET 'https://macromap.cxkjedu.com/api/open/seats' \
--header 'content-type:application/json; charset=utf-8' \
--header 'open-token: d13fc57d46bac217'
响应体
名称 | 类型 | 描述 |
---|---|---|
status | string | 接口状态 SUCCESS 表示成功 |
code | int | 响应代码 200 表示成功 |
msg | string | 错误描述 |
data | seat[] | 客位列表 |
∟ id | int | 客位 ID |
∟ table_number | string | 桌号 |
∟ remark | string | 备注 |
∟ status | string | 客位状态 :-1 禁用 0 正常 |
∟ merchant_id | string | 商户账号 |
∟ user_id | int | 商户 ID |
∟ created_at | string | 创建时间 |
∟ updated_at | string | 修改时间 |
响应体示例
{
"status": "SUCCESS",
"code": 200,
"data": [
{
"id": 4,
"table_number": 1,
"remark": null,
"user_id": 3,
"merchant_id": "cxexxxxxxxx",
"status": 0,
"created_at": "2022-07-23 12:33",
"updated_at": "2022-07-23 12:33"
},
{
"id": 5,
"table_number": 2,
"remark": "包厢01",
"user_id": 3,
"merchant_id": "cxexxxxxxxx",
"status": 0,
"created_at": "2022-07-24 06:16",
"updated_at": "2022-07-24 06:16"
}
]
}
客位信息 ¶
查询客位信息
请求
基本 | |
---|---|
HTTP URL | https://macromap.cxkjedu.com/api/open/seats/:seat_id |
HTTP Method | GET |
请求头
名称 | 类型 | 必填 | 描述 |
---|---|---|---|
Content-Type | string | 是 | 固定值:"application/json; charset=utf-8" |
open-token | string | 是 | app_api_token 示例值:"d13fc57d46bac217" 了解更多:获取访问凭证 api_token |
查询参数
名称 | 类型 | 必填 | 描述 |
---|---|---|---|
seat_id | string | 是 | 客位 ID 示例值:"1" |
请求体
该请求无请求体
请求体示例
$ curl --location --request GET 'https://macromap.cxkjedu.com/api/open/seats/1' \
--header 'content-type:application/json; charset=utf-8' \
--header 'open-token: d13fc57d46bac217'
响应体
名称 | 类型 | 描述 |
---|---|---|
status | string | 接口状态 SUCCESS 表示成功 |
code | int | 响应代码 200 表示成功 |
msg | string | 错误描述 |
data | seat | 客位数据 |
∟ id | int | 客位 ID |
∟ table_number | string | 桌号 |
∟ remark | string | 备注 |
∟ status | string | 客位状态 :-1 禁用 0 正常 |
∟ merchant_id | string | 商户账号 |
∟ user_id | int | 商户 ID |
∟ created_at | string | 创建时间 |
∟ updated_at | string | 修改时间 |
响应体示例
{
"status": "SUCCESS",
"code": 200,
"data": {
"id": 5,
"table_number": 2,
"remark": "包厢01",
"user_id": 3,
"merchant_id": "cxexxxxxxxx",
"status": 0,
"created_at": "2022-07-24 06:16",
"updated_at": "2022-07-24 06:16"
}
}