How to send custom commands to the device via API

GPS1a year ago

Thank you Anton for pointing me in the good direction to search .

The right way to use curl for sending command via bash terminal is :

curl http://admin:mypass@myserveraddress/api/commands/send -H 'content-type: application/json' -d {"id":0,"description":"New\u2026","deviceId":312,"type":"custom","textChannel":false,"attributes":{"data":"getstatus"}}
Matyi Szabolcsa year ago

Hi GPS1,

Can you also give me the curl command with which I can list the devices, which are offline and which are online?

This is what I've tried so far:

[alpine-gps]~ > curl -X GET --data "email=admin&password=blabla" http://localhost:8082/api/devices
HTTP 415 Unsupported Media Type - NotSupportedException (... < OverrideFilter:50 < ...)

Thanks!