Skip to content
On this page

客位数据接口

客位列表

获取当前商户客位列表

请求

基本
HTTP URLhttps://macromap.cxkjedu.com/api/open/seats
HTTP MethodGET

请求头

名称类型必填描述
Content-Typestring固定值:"application/json; charset=utf-8"
open-tokenstringapp_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'

响应体

名称类型描述
statusstring接口状态 SUCCESS 表示成功
codeint响应代码 200 表示成功
msgstring错误描述
dataseat[]客位列表
∟ idint客位 ID
∟ table_numberstring桌号
∟ remarkstring备注
∟ statusstring客位状态 :-1 禁用 0 正常
∟ merchant_idstring商户账号
∟ user_idint商户 ID
∟ created_atstring创建时间
∟ updated_atstring修改时间

响应体示例

{
    "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 URLhttps://macromap.cxkjedu.com/api/open/seats/:seat_id
HTTP MethodGET

请求头

名称类型必填描述
Content-Typestring固定值:"application/json; charset=utf-8"
open-tokenstringapp_api_token
示例值:"d13fc57d46bac217"
了解更多:获取访问凭证 api_token

查询参数

名称类型必填描述
seat_idstring客位 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'

响应体

名称类型描述
statusstring接口状态 SUCCESS 表示成功
codeint响应代码 200 表示成功
msgstring错误描述
dataseat客位数据
∟ idint客位 ID
∟ table_numberstring桌号
∟ remarkstring备注
∟ statusstring客位状态 :-1 禁用 0 正常
∟ merchant_idstring商户账号
∟ user_idint商户 ID
∟ created_atstring创建时间
∟ updated_atstring修改时间

响应体示例

{
    "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"
    }
}