- Authenticated with Golioth - see Authentication
- Have a project - see Create a Project
- Have a provisioned device and credential for it - see Authorizing Devices
Our platform provides functionality for tracking your devices logs, so you can have a better sense of things that are happening out in the field.
An endpoint is provided on our gateways on the
/logs path where the device can send log data. Right now only the CoAP gateway is available to use this service.
Data can be sent using query parameters and also on the message body. The message body can be send in CBOR or JSON format and is going to be parsed and we will try to identify the known attributes as presented bellow. If the body is sent as plain text, it will be saved as the log entry message.
|Timestamp of the log entry||now()|
|level||Log Level - Can be info/warn/error/debug||info|
|module||Internal module that is generating logs|
|Free form string with the log message|
|Any other attribute sent over this endpoint is bundled into a |
Simulating device logs using
You can simulate sending logs by using
coap and POSTing data to the
In the example bellow, we are sending the parameters
network as query parameters and also a message in JSON format in the body containing the log
After sending a log entry you can search logs using
goliothctl. Check the next page for more details on how to do that.