Sensr REST API§
The following document represents a brief guide from the REST API offered by Sensr.
How to use§
The rest API is easily accessible from the port 9080 while Sensr is running, you can access it either from http://localhost:9080/ or http://{your-ip-here}:9080/
With our REST API you can query/set the values of configurations, send commands, or query object/zone details. These behaviours are mapped into the below resources.
Resources§
- /results
- This resource returns a json formatted data of detail of a object or a zone.
- /settings/project
- Control project configuration.
- /settings/algorithm
- Control algorithm configuration.
- /settings/sensor
- Control general sensor configuration.
- /settings/sensor-ext
- Control sensor configuration.
- /settings/node
- Control algo node configuration.
- /settings/zone
- Control zone configuration.
- /commands
- This resource takes a command. The SENSR server will perform a specific action based on the command.
Trying to write a read-only parameter the API will result in the server returning an error value back as response.
If you want to access a specific parameter category, you will need to first access the corresponding route.
Once you have chosen the correct route you will have access to the following sub-routes: