https://api.sciener.com/v3/lock/setAutoLockTime
设置锁的自动闭锁时间,开锁后锁会在设置的秒数后自动关闭。
POST, ContentType:application/x-www-form-urlencoded
xxxxxxxxxxcurl --location -g --request POST 'https://api.sciener.com/v3/lock/setAutoLockTime' \--data-urlencode 'clientId=4773aa036f7f49c68d876bb4be85c80c' \--data-urlencode 'accessToken=dfd5489d0cee31f0bdfaf59d0d42d71f' \--data-urlencode 'lockId=163377' \--data-urlencode 'seconds=10' \--data-urlencode 'type=2' \--data-urlencode 'date=1625025703000'| 名称 | 类型 | 是否必需 | 描述 |
|---|---|---|---|
| clientId | String | Y | 创建应用分配的client_id |
| accessToken | String | Y | 访问令牌,通过获取访问令牌接口获取 |
| lockId | Int | Y | 锁ID,由锁初始化接口生成 |
| seconds | Int | Y | 开锁后,锁会在设置的秒数后自动关闭,传0或-1表示关闭自动闭锁 |
| type | Int | Y | 设置方式: 1-通过APP蓝牙,必需先通过APP SDK蓝牙设置自动闭锁时间后再调用该接口 2-通过网关或WiFi锁,如果是WiFi锁或有连接网关,传2可通过云端接口直接设置生效, 不传默认1。 |
| date | Long | Y | 当前时间(时间戳,单位毫秒) |
| 参数 | 类型 | 描述 |
|---|---|---|
| errcode | Int | 错误码 |
| errmsg | String | 错误信息 |
| description | String | 错误描述 |
xxxxxxxxxx{"errcode": 0,"errmsg": "none error message","description":"表示成功或是"}