Track Custom Events
Track events are used to track user behavior and drive analytics. Simply call the logEvent to track custom events or see new feature adoption. you can provide optional metadata to be logged with the event.
devunusClient.logEvent('add_to_cart', { product_id: '1234', quantity: 2 })
metadata may be of type boolean, number, or string. Please see limits below
- Event names have a maximum of 60 characters.
- A maximum of 1KB of metadata is supported
Events with reliability and performance metrics
Measure how long tasks are taking to complete or how often tasks are succeeding. All functions accept optional metadata that can be recorded against the event.
These will be shown in the reliability Performance screen
const task = devunusClient.getMeasure('event-name'); // will create and start the timer
try {
// processing
task.done();
}
catch (err) {
task.fail({ error: err });
}