V2.1 List Device Current Firmware¶
List the firmware versions of all devices under the specified product.
This API is available in EnOS 2.2.0 and above.
Operation Permissions¶
Before invoking this API, ensure that the service account has been authorized the policy that includes the following service(s) and action permission(s). For how to authorize the service account, see Managing Service Accounts.
Required Service |
Required Operation Permission |
---|---|
Firmware |
Read |
Request Format¶
GET https://{apigw-address}/connect-service/v2.1/ota-firmwares?action=listVersion
Request Parameters (URI)¶
Name |
Location(Path/Query) |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|---|
orgId |
Query |
Mandatory |
String |
The organization ID which the asset belongs to. How to get orgId>> |
productKey |
Query |
Mandatory |
String |
The product key. |
Response Parameters¶
Name |
Data Type |
Description |
---|---|---|
data |
String Array |
The list of firmware versions. |
Error Codes¶
For the description of error codes, see Common Error Codes.
Samples¶
Request Sample¶
url: https://{apigw-address}/connect-service/v2.1/ota-firmwares?action=listVersion&orgId=yourOrgId&productKey=yourProductKey
method: GET
Return Sample¶
{
"code": 0,
"msg": "OK",
"requestId": "59b92d01-1b8b-44a4-8e6a-01f7d9d256f2",
"data": [
"7.7",
"2.0",
"7777",
"AOTA"
]
}
SDK Samples¶
You can access the SDK samples for Connection Service on GitHub: