The one key
analytics sits on a node, beside the action it accompanies.
event is the name that arrives in the analytics tool. params are the values
sent with it.
{{...}} reads the data already in scope at that node. It is the same binding an actionβs
values use, so there is nothing new to learn.
A node with no analytics block reports nothing. Silence is the default.
Opening a view is an action
A card and its detail view are one instance. Opening the detail view writesview (the
public state; legacy spelling defaultState), which is an action like any other. So it
takes the same key.
Choosing event names
Use the analytics toolβs own vocabulary where it has a word for what happened. GA4 definesview_item, generate_lead, select_item and others. Those names populate its built-in
reports with no setup.
Invent a name only when no standard one fits. Prefix it with unoverse_ so it cannot
collide with an event the page already fires.
Names are yours to choose. The platform holds no list.
Choosing params
Send what answers a question somebody will ask. Leave out anything that only describes the machinery. Match the field names the customerβs own analytics already uses. Their reports and filters are built on those names, so a matching param joins work they have already done. A generic name arrives as a column somebody has to map by hand.What never goes in an event
Three rules, and breaking any of them is a data protection problem rather than a bug. No personal data. No name, email, phone or date of birth. Analytics tools prohibit it, and the property receiving it belongs to your customer. No authored content. Report which item somebody opened. Never report what it said. No typed text. A personβs question or form entry stays out. Both routinely contain personal detail. An enquiry event carries an opaque reference to the record, never the record.One event per kind of thing
A course, a product and a service are the same moment. Somebody looked at one thing in detail. Give them one event and separate them with a param.view_course and view_product fragments the reporting. An analytics
tool breaks one event down by param automatically. It cannot recombine two event names into
one funnel.
Where events go is not your decision
You declare what happened. The destination is configured per customer, outsiderx/.
The reason is practical. The same template runs on a customerβs site, in the Unoverse
client, and inside an MCP app host. Each has a different destination, or none. A template
cannot know which one it is in.
Analytics is off unless a customer has been configured. Your declarations sit dormant until
then, and cost nothing.
Checking your events
Turn on debug for the channel you are testing. Each event prints as it fires.unoverse:analytics to see only these.
Troubleshooting
Related
- Components for the node grammar
- State for how a view change is a state write
- Lifecycle Hooks for fetching data at a moment, which is a different job

