创建假日计划

  • 接口功能

创建假日计划,不生效,需要再开启计划;
同一时间,一个智能锁只允许被一个用户操作;

  • 请求地址

https://open.ys7.com/api/component/saas/smartlock/openplan/holiday/add

  • 请求方式

POST

  • 参数列表
参数名 类型 描述 是否必填
accessToken String 开放平台授权获取的访问令牌 Y
planName String 计划名称 Y
deviceSerial String 智能锁序列号 Y
channelNo String 计划序号(1~16) Y
planBegin Date 开始时间(yyyy/MM/dd HH:mm:ss) Y
planEnd Date 结束时间(yyyy/MM/dd HH:mm:ss) Y
timePairEntityList Object[] 计划时间段列表 Y
timePairEntityList[i].beginTime Time 时间段开始时间(HH:ss:mm) Y
timePairEntityList[i].endTime Time 时间段结束时间(HH:ss:mm) Y
  • 请求报文
POST https://open.ys7.com/api/component/saas/smartlock/openplan/holiday/add HTTP/1.1
Host: open.ys7.com
content-type: application/x-www-form-urlencoded
accessToken=at.0l99iqik8zwycxie3pn74on632amm7py-3d448c4jz3-1pkjlze-zpjbs9x5d&deviceSerial=K43763512&planName=adsvc&holidayChannel=1&planBegin=2023%2F02%2F15%2000%3A00%3A00&planEnd=2023%2F02%2F15%2020%3A00%3A00&timePairEntityList%5B0%5D.beginTime=00%3A00%3A00&timePairEntityList%5B0%5D.endTime=19%3A00%3A00
  • 返回数据
{
    "code": "200",
    "msg": "操作成功",
    "planId": "142"
}
  • 参数说明
参数名 类型 描述 是否必须
code int 状态码-200,表示通过云端校验,成功开始与设备交互;
权限是否下发成功请根据data中authorityStatus判断
Y
msg String 具体错误描述信息 Y
planId Long 计划id Y

results matching ""

    No results matching ""