Tabla de Contenidos |
---|
APIv3
For APIv3, the Swagger documentation offers interactive curl examples:
Please use the Swagger docs to explore the APIv3:
https://download-unimus.netcore.software/api-v3-preview/
APIv2
For APIv2 curl examples, please see below.
Format of curl examples
The curl examples will use this format:
...
The above curl command is the same as if written on one line (without the use of json_pp here):
Bloque de Código |
---|
curl -sS -H "'Authorization: Bearer <token>" "' -d '<data>' 'http://<unimus-address>:8085/api/v2/<API-path>"' | json_pp |
You will need to substitute the values inside <...> for your actual values:
...
curl call:
Bloque de Código |
---|
curl -ssS \ -H 'Authorization: Bearer <token>' \ 'http://<unimus-address>:8085/api/v2/health' | json_pp |
...
curl call:
Bloque de Código |
---|
curl -ssS \ -H 'Content-type: application/json' \ -H 'Authorization: Bearer <token>' \ -d '{"address":"<address>"}' \ 'http://<unimus-address>:8085/api/v2/devices' | json_pp |
...
curl call:
Bloque de Código |
---|
curl -ssS \ -H 'Authorization: Bearer <token>' \ 'http://<unimus-address>:8085/api/v2/devices/findByAddress/1.1.1.1' | json_pp |
...
curl call:
Bloque de Código |
---|
curl -ssS \ -H 'Authorization: Bearer <token>' \ -X PATCH \ 'http://<unimus-address>:8085/api/v2/jobs/backup?id=57' | json_pp |
...
curl call:
Bloque de Código |
---|
curl -ssS \ -H 'Authorization: Bearer <token>' \ 'http://<unimus-address>:8085/api/v2/devices/57/backups/latest' | json_pp |
...