Once the Zenovay tracker is loaded on your page, it exposes a global function window.zenovay() that accepts a custom event name and an optional properties object. Use it to track anything that isn't a pageview — clicks, form submissions, business events.
The simplest call
window.zenovay('cta_clicked');
That sends a single event with no properties. It will appear in Events → Custom Events in your dashboard within ~30 seconds.
With properties
window.zenovay('cta_clicked', {
cta_label: 'Start free trial',
page_section: 'hero',
variant: 'B'
});
Property values can be strings, numbers, or booleans. Nested objects and arrays are not supported — flatten them at the call site.
Revenue events
For purchases, use the special revenue field:
window.zenovay('purchase', {
revenue: 29.00,
currency: 'USD',
product_id: 'pro-annual',
customer_id: 'cust_123'
});
The revenue and currency fields populate your revenue dashboard. customer_id is optional but enables identified-user analytics if you set it.
Identifying a user
When a visitor logs in, link the anonymous session to their account:
window.zenovay.identify('user_42', {
email: 'jane@example.com',
plan: 'pro'
});
After this call, all subsequent events are tagged with user_42 until the page reloads or you call window.zenovay.reset() (e.g. on logout).
Property naming conventions
Use snake_case (page_section, not pageSection). The dashboard groups properties alphabetically — consistent naming makes filters easier.
Reserved names that the tracker sets automatically and you should NOT override:
url,referrer,screen_size,browser,os,country,city
If you set them, they're silently dropped.
Plan limits
Custom events count toward your monthly event quota:
| Plan | Monthly events |
|---|---|
| Free | 10,000 |
| Pro | 100,000 |
| Scale | 1,000,000 |
| Enterprise | Custom |
Common pitfalls
- Calling before the tracker loaded — wrap calls in a
if (window.zenovay)check, or use the deferred queue:window.zenovayQueue = window.zenovayQueue || []; window.zenovayQueue.push(['cta_clicked']). - Sending PII as a property — emails, names, phone numbers should not be sent as custom event properties. Use
identify()instead, where the data is hashed at rest. - Cookieless mode +
identify()— when running in cookieless mode the identify call still works for the current page, but the link is reset on the next page load (no persistent storage).