Several questions;
Trying to use this API:
/api/v1/operations/systems/atcommand
as documented here:
https://doc.airvantage.net/av/reference/cloud/API/API-System-v1/
I am using this curl command
% curl -X POST -H ‘Content-Type: application/json’ -H ‘Accept: application/json’ -H ‘Authorization: Bearer w8rzveESxUn8VT1_twofbMWmXI27jtPyF0VxxwaGC8lY1Gdcw6uvQ6gEYX9Ho9LXhqm15W7704sFM4v8aj2s7Q’ -vvv -d @‘./at.json’ ‘https://na.airvantage.net/api/v1/operations/systems/atcommand’
with this data payload in the file at.json
{
“systems” : {
“uids” : [“9d4b7aa097584455a4026ec0ededc043”],
“labels” : [“Michael”]
},
“atcommand” : “AT*NBSIMPRESENT?”
}
In an example shown in the documentation (replicated below), there is an optional element called action: There is some capability in the API that leverages this concept of an “action”, but I can’t find anything that describes what an action really is and how it’s supposed to work. Can anyone clear this up?
In addition,
{
“systems” : {
“label” : “labege”
},
“atcommand” : “AT+CGMR”,
“action” : “OPENAT_AT_COMMAND”
}
When I submit the AT command, the system does pick it up and run with it - I get an operation uid back and I use that to check status as below:
curl -X GET -H ‘Authorization: Bearer 1s-cZOcvCDUwPE_xM5PJxmAMu0hy-NjjHaemG4tmJDQXgGfdtwici6hEWSBSBAwjUZrbuaqrx_fVR_S1HjYv4Q’ ‘https://na.airvantage.net/api/v1/operations/70e8f55e48114e68bd0d73382c439215/tasks’
{“items”:[{“date”:1659719828884,“input”:null,“state”:“FAILURE”,“uid”:“01826f02c52043888b762086ae921775”,“createdAt”:1659719828768,“rank”:0,“messages”:[{“date”:1659719828853,“type”:“ERROR”,“message”:“operation.send.at.command.missing.at.command.action.in.system”}],“executedAt”:1659719828849,“targetDescription”:{“uid”:“9d4b7aa097584455a4026ec0ededc043”,“name”:“MLASpare_5_mw01.vwstatic_ATT_primary_ATT_slot2”},“target”:“9d4b7aa097584455a4026ec0ededc043”}],“count”:1,“size”:1,“offset”:0}%
The error message has to do with a missing action. (ERROR",“message”:“operation.send.at.command.missing.at.command.action.in.system”})
Please share some detail on what an action is and how I could use it.