跳到主要内容

远程控制

TOKEN获取方式​

第1步 登录北向平台​

第2步 获取应用id与密钥​

第3步 请求TOKEN​

  • 接口路径:https://www.lian-yun.cn/smkgw/inorthmanageservice/api/v1.0.0/northreport/open/token/import
  • 请求方法:POST
  • 请求头:无
  • 请求参数(multipart/form-data):
参数名称参数类型必填说明
appIdstring是应用ID
appSecretstring是密钥
  • 返回结果:
参数名称参数类型必填说明
codestring是错误码,200表示成功,其它表示失败
messagestring否错误描述
access_tokenstring否token串,有效期2小时

接口列表​

1. 远程控制空开​

  • 接口路径: https://www.lian-yun.cn/smkgw/inorthmanageservice/api/v1.0.0/northreport/open/command/switch/send/import
  • 接口调用频率限制:200次/分
  • 请求方法:POST
  • 请求头:
参数名称参数类型必填说明内容
Authorizationstring是头部校验串Basic:{access_token}
  • 请求参数(multipart/form-data):
参数名称参数类型必填说明
deviceIdstring是设备平台编码
switchStatestring否控制动作,0-分闸 1-合闸
lineNumbersstring否控制具体开关,多个使用逗号分隔:12321,43132
  • 返回结果:
参数名称参数类型必填说明
codestring是错误码,200表示成功,其它表示失败
messagestring否错误描述

2. 远程控制消音​

  • 接口路径: https://www.lian-yun.cn/smkgw/inorthmanageservice/api/v1.0.0/northreport/open/command/send/import
  • 接口调用频率限制:10次/秒
  • 请求方法:POST
  • 请求头:
参数名称参数类型必填说明内容
Authorizationstring是头部校验串Basic:{access_token}
  • 请求参数(multipart/form-data):
参数名称参数类型必填说明
deviceTypestring是设备类型编码:如烟感-smoke 手报-hand
deviceNostring是设备imei号
commandTypestring是控制指令,如:消音-mute
  • 返回结果:
参数名称参数类型必填说明
codestring是错误码,200表示成功,其它表示失败
messagestring否错误描述