Detect if token is valid

Request format: GET

URL: http://ota.heclouds.com/ota/south/download/{token}/check

This API can be used as needed during device upgrade process by users, and this operation is optional.

I only want to see examples!!!

http header

Name Format Required or not Description
Content-Type string Yes Must be application/json.
Authorization string Yes Security authentication information

http request parameter

Name Format Required or not Description
dev_id long Yes Device id

Return Parameter

Name Format Description
errno int Call error code, where 0 means success.
error string Error description, where “succ” means success.

Error Code Description

Error CodesDescription
0Valid
4Token and did are inconsistent.
7OneNET internal error.
12Token is expired and device upgrade process flow is ended.
17Invalid status. Token can only be verified when the upgrade task of the device is to be upgraded or under downloading. Token verification is not supported in other status.
20Upgrade task is completed and device upgrade process is ended.
21Invalid operation, sdk logic error.
22Upgrade task is cancelled, it is unnecessary to report upgrade failure.

Description

  1. After obtaining task information through task detection interface for the device, it is required to carry out token detection through token detection interface (since token is only valid within 2 days).

  2. After token detection interface is called successfully, the platform will change device upgrade task status from “to be upgraded” to “downloading”.

Return Example

{
    "errno": 0,
    "error": "succ"

}

个搜索结果,搜索内容 “

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