Skip to content

初始化配置


API请求

请求URL

POST

https://{host}/api/rentbox/client/config?rentboxSN={rentboxSN}&sign={sign} 

text
/api/rentbox/client/config
text
Content-Type:text/plain

请求参数

名称标识代码是否必填备注
服务器域名hostYES客户提供,例如:s.abc.com
设备全球唯一码rentboxSNYES4G通讯模块,IMEI号
接口签名signYESMD5加密

Body

设备调试信息,客户对接无需关注

json
{
    "APN":"AT+QICSGP=1,1,\"3gnet\",\"\",\"\",0",
    "soft":"V6089",
    "hard":"V2004",
    "CRC16":"0x240D",
    "EC20_Mead":"Quectel",
    "EC20_Type":"EC200N",
    "EC20_Version":"EC200NCNLAR03A02M08_DO"
}

接口签名

text
sign=MD5("rentboxSN={rentboxSN}")

请求示例

text
Content-Type:text/plain

Body

{"APN":"AT+QICSGP=1,1,"3gnet","","",0","soft":"V6089","hard":"V2004","CRC16":"0x240D","EC20_Mead":"Quectel","EC20_Type":"EC200N","EC20_Version":"EC200NCNLAR03A02M08_DO"}

sign = 005dca9b80163313e88f249763ac96e9

MD5("rentboxSN=860602069165357")

响应结果

json
{
    "code":200,
    "type":0,
    "data":"{\"dRotationRefer\":\"15\",\"dReturnLocked\":\"0\",\"dHeadConfig\":\"43\",\"dRotationNumber\":\"4\",\"dRotationEnable\":\"1\",\"dMotorEnable\":\"1\",\"dAreaConfig\":\"4\"}",
    "msg":"OK",
    "time":1705479269271
}
名称标识代码类型备注
状态码codeint默认:200
状态类型typeint默认:0
自定义数据datastring配置参数,字符串需转义JSON对象
异常消息msgstring默认:OK
时间戳timelong当前毫秒时间戳

配置参数

json
{
    "dRotationRefer":"15",
    "dReturnLocked":"0",
    "dHeadConfig":"43",
    "dRotationNumber":"4",
    "dRotationEnable":"0",
    "dMotorEnable":"0",
    "dAreaConfig":"0"
}
名称标识代码类型备注
dRotationReferdRotationReferstring柜机自检时间(分钟):默认15
dReturnLockeddReturnLockedstring预留值:默认0
dHeadConfigdHeadConfigstring预留值:默认43
dRotationNumberdRotationNumberstring预留值:默认4
dRotationEnabledRotationEnablestring预留值:默认0
dMotorEnabledMotorEnablestring预留值:默认0
dAreaConfigdAreaConfigstring区域码(客户定制),默认0