Skip to content

授权码

说明:主要对授权码进行一些基础操作,例如获取授权码、查询TPP支持等。

获取授权码

  • 调用方法
javascript
POST /api/authCode/getActivateInfo
  • 参数说明
名称类型是否必需示例描述
register_keystringY"key123"授权池动态注册密钥 锁中获取
platformintY2平台ID 通过【查询TPP支持】的API获取
modelstringY"xxWIFI门锁"锁的型号
serial_num0stringY"1234567890"锁的唯一ID
  • 返回说明
名称类型描述
auth_codestring授权码
activated_atstring激活时间
extra_paramsobject额外参数
  • 返回示例
json
{
  "errorCode": 0,
  "description": "",
  "data": {
    "auth_code": "",
    "activated_at": "2025-08-06 10:00:00",
    "extra_params": null
  }
}

查询TPP支持

  • 调用方法
javascript
POST /api/authCode/getTppSupport
  • 参数说明
名称类型是否必需示例描述
modelstringY"xxWIFI门锁"锁的型号
  • 返回说明
名称类型描述
platformint平台ID
platform_namestring平台名称
  • 返回示例
json
{
  "errorCode": 0,
  "description": "",
  "data": [
    {
      "platform": 2,
      "platform_name": "涂鸦平台"
    }
  ]
}

鑫泓佳智能硬件通信协议文档