Query device id based on the unique identification of the device.

Request format:GET

URL: http://ota.heclouds.com/ota/devInfo

I only want to see examples!!!

Device ID is a unique ID No. assigned by the platform to each device. If your device has not yet obtained the device ID and needs to be upgraded when accessing the platform for the first time, device ID can be obtained using the unique identification through this interface.

http header

NameFormatRequired or notDescription
Content-TypestringYesMust be application/json.
AuthorizationstringYesSecurity authentication information

http request body

NameFormatRequired or notDescription
pidlongYesProduct id
authInfostringYes Unique device identification, please refer to the following for details.

Return Parameters

NameFormatDescription
errnointCall error code, where 0 means success.
error stringError description, where “succ” means success.
data jsonDevice-related information returned after interface is successfully called. See the Data Description Table.

Data Description Table

NameFormatDescription
dev_idstringDevice ID

Description

The meaning corresponding to the request parameter authInfo is different based on different product protocols. The details are as below:

  1. If NB protocol is used for the product, the unique device identification is the “IMEI” field when creating the device on the platform.

  2. If MQTTS protocol (new version MQTT) is used for the product, the unique device identification is the “device name” field when creating the device on the platform.

  3. If MQTT/EDP/TCP pass-through protocol is used for the product, the unique device identification is the “authentication information” field when creating the device on the platform.

  4. If HTTP protocol is used for the product, the unique device identification is the “device number” field when creating the device on the platform.

  5. If Modbus protocol is used for the product, the unique device identification is the json string consisting of “DTU serial number” and “DTU password” field when creating the device on the platform.

  6. If JT/T808 protocol is used for the product, the unique device identification is the json string consisting of “terminal model” and “terminal ID” field when creating the device on the platform.

Request Example

{

    "pid":123,

    "authInfo":"869975036903162"//NB unique device identification is IMEI number. Please refer to above “Explanation” for other protocols.

}

Return examples

{

"errno": 0,
"error":"succ",
"data":
      {
      "dev_id":"233444"
      }

}

个搜索结果,搜索内容 “

    0 个搜索结果,搜索内容 “