Skip to main content
Every event your code sends appears in the dashboard at https://grainql.com/dashboard. This checklist holds the practices that make those events useful there. Each item states the reason, shows one example, and links the page that holds the details. The examples use Analytics Web. Grain Tag sends the same events with GrainTag.track and the same names and properties.
1

Name an event as object and action

The dashboard lists events by name. checkout_completed says what happened, and action does not. Use lowercase words with underscores.
Read Name events.
2

Use the same property names on related events

A track or a filter that spans several events matches on the property name. When video_started sends video_id and video_paused sends id, the dashboard cannot join them.
3

Put the context in properties

A filter in the dashboard reads properties, not the event name. An event with category and source can be grouped by both.
Read Track an event.
4

Use a template event for login, signup, cart, checkout, purchase, and search

A template method sends a fixed event name with typed properties, so every part of the code sends the same event.
Read Template events.
5

Identify the user after login

Without a user ID, the events of one person on two days are two anonymous visitors. After identify, they are one journey.
Read Identify users.
6

Store segments as user properties

A user property such as plan lets the dashboard compare groups of users, and remote configuration reads it to pick a value.
Read User properties.
7

Send one event per step of a funnel

A track shows where users leave a flow. It needs one event per step, in order.
Read Tracks.
8

Track an error as an event

An error event with error_type and error_message shows in the dashboard next to the events that came before it.
9

Flush an event that comes right before a navigation

The SDK batches events. An event that a redirect follows, such as a purchase, must go out before the page unloads.
Read Track an event.
10

Do not track page views and sessions by hand

Both SDKs send page views, sessions, and heartbeats without code. A manual copy doubles the counts.Read Automatic tracking.
For a custom dashboard on top of the same events, use the Query API. Read Export and query data.