IotHub
  1. command
IotHub
  • README
  • Update Record
  • token
    • createToken
      POST
    • destroyToken
      POST
  • customer
    • customerPage
      POST
    • customerTree
      POST
  • device
    • command
      • commandSend
        POST
      • commandInfoList
        POST
      • cutOilElectric
        POST
      • getConfig
        POST
    • devicePage
      POST
    • deviceTypes
      POST
    • deviceTypeInfo
      POST
    • deviceDataByDeviceIds
      POST
    • deviceDataByCustomerId
      POST
    • deviceTripInfoByTripId
      POST
    • deviceTripsByDeviceId
      POST
    • expandInfoByDeviceId
      POST
    • saveDeviceChannelName
      POST
  • fence
    • fencePage
      POST
    • fenceInfo
      POST
    • addFence
      POST
    • saveFence
      POST
    • delFence
      POST
    • fenceDevices
      POST
    • fenceDeviceUpdate
      POST
    • fenceDeviceDel
      POST
    • fenceDeviceAdd
      POST
  • push
    • README
  • video
    • H5 page
    • H5 Page-V2
    • liveVideo
    • playBackList
    • historicalUpload
    • playBack
    • replaySet
    • taskPage
    • taskDelete
    • getNodes
  • alarm
    • alarmTypeList
    • alarmFilePage
    • alarmFileByAlarmId
    • alarmHistoryPage
    • alarmPageByUser
  • audio
    • README
    • talk
    • talkPlus
  • gallery
    • filePageV2
    • filePage
    • deleteFile
    • capture
    • capturePage
  • fleet
    • faceRecordPage
  • gps
    • historyData
  • Protocol Analysis
    POST
  1. command

commandInfoList

Singapore
https://mettahub.mettaxiot.com/gps
Singapore
https://mettahub.mettaxiot.com/gps
POST
/v2/openapi/device/command/recently

Request

Header Params
Authorization
string 
required
Body Params application/json
customerId
string  | null 
optional
customerId
deviceId
string  | null 
optional
deviceId
type
string  | null 
optional
type CUSTOM
commandStatus
integer  | null 
optional
Command status awaiting reply 0 success 1 failure 2 pending execution 3 canceled 4 timeout 5
commandId
string  | null 
optional
commandId
limit
integer  | null 
required
Number of instructions queried 1-3
>= 1<= 3
Example
{
    "customerId": "string",
    "deviceId": "string",
    "type": "string",
    "commandStatus": 0,
    "commandId": "string",
    "limit": 1
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://mettahub.mettaxiot.com/gps/v2/openapi/device/command/recently' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
    "customerId": "string",
    "deviceId": "string",
    "type": "string",
    "commandStatus": 0,
    "commandId": "string",
    "limit": 1
}'

Responses

🟢200Success
application/json
Body
code
integer  | null 
optional
data
array[object (ApiDeviceCommandVO) {10}]  | null 
optional
id
string  | null 
optional
id
deviceId
string  | null 
optional
deviceId
commandText
string  | null 
optional
commandText
commandTextReply
string  | null 
optional
commandTextReply
subProtocol
string  | null 
optional
subProtocol
type
string  | null 
optional
type
customerId
string  | null 
optional
customerId
commandStatus
integer  | null 
optional
Command status awaiting reply 0 success 1 failure 2 pending execution 3 canceled 4 timeout 5
sendTime
string  | null 
optional
Command sending time yyyy-MM-dd HH:mm:ss UTF-0
endTime
string  | null 
optional
Command response time yyyy-MM-dd HH:mm:ss UTF-0
msg
string  | null 
optional
Example
{
  "code": 0,
  "data": [
    {
      "id": "",
      "deviceId": "",
      "commandText": "",
      "commandTextReply": "",
      "subProtocol": "",
      "type": "",
      "customerId": "",
      "commandStatus": 0,
      "sendTime": "",
      "endTime": ""
    }
  ],
  "msg": ""
}
Modified at 2024-09-26 03:15:34
Previous
commandSend
Next
cutOilElectric
Built with