Logs
Logs are your friends in Nexitor, they provide you with all kinds of information ranging from successful transactions up to critical errors, nothing goes unnoticed as long as you keep logging.
Searching for Logs
To search for Logs you can simply just use the full text search as it provides results in a matter of Milliseconds.
Filtering Logs
To filter for logs you can use the filters on the top. Each selected filter will be immediately applied. All incoming logs will also be filtered accordingly.
Sending Logs
See the example below of a generic HTTP post request you can use to send logs:
axios.post('https://your-instance.nexitor.io/log', {
status: '200',
title: 'GET - /user',
user_name: 'Alice Brown',
user_identifier: 'c9cdbd17-9b44-4fbb-8199-d6bc7d6c2a1a',
user_ip: '127.0.0.1',
message: 'My first log',
payload: '{maxAge: 56}',
stacktrace: 'Test Stacktrace',
application: 'Nexitor',
instance: 'Staging'
}, {
headers: {
Authorization: `Bearer ${token}`
}
})
Note This
We are working on providing modules and packages that will automate the logging process for popular frameworks. We are also looking into supporting OpenTelemetry standards.
Log attributes
Attribute | Optional | Default | Description |
---|---|---|---|
status | Yes | "Log" | HTTP Status or other meaningful status identifier such as ERROR, SUCCESS |
instance | Yes | "Development" | Name of the instance |
application | Yes | "Nexitor" | Name of the application |
title | No | "-" | Title of the Log will be displayed on the uncollapsed log |
user_name | Yes | "-" | Name of the user that initiated the transaction |
user_identifier | Yes | "-" | Unique identifier of the user |
user_ip | Yes | "0.0.0.0" | IP of the user that initiated the transaction |
message | Yes | "-" | Further description of the log |
payload | Yes | "-" | Payload data |
stacktrace | Yes | "-" | Error description |