Skip to main content

For AI agents: a Markdown version of this page is at https://docs.snowplow.io/docs/sources/web-trackers/previous-versions/web-trackers-v3/tracking-events/event-specifications.md. The index of all documentation pages is at https://docs.snowplow.io/llms.txt, and the index for this section is at https://docs.snowplow.io/docs/api-reference/llms.txt.

Event specifications

caution
You are reading documentation for an outdated version. Here's the latest one!

The plugin allows you to integrate with Event Specifications for a selected set of plugins. The configuration for the plugin should be retrieved directly from your tracking plan in Snowplow Console.

The plugin will automatically add an Event Specification context to the events matching the configuration added.

note

The plugin is available since version 3.23 of the tracker.

Install plugin​

  • npm install @snowplow/browser-plugin-event-specifications@3
  • yarn add @snowplow/browser-plugin-event-specifications@3
  • pnpm add @snowplow/browser-plugin-event-specifications@3
javascript
import { newTracker } from '@snowplow/browser-tracker';
import { WebVitalsPlugin } from '@snowplow/browser-plugin-event-specifications';

newTracker('sp1', '{{collector_url}}', {
appId: 'my-app-id',
plugins: [ EventSpecificationsPlugin(/* plugin configuration */) ],
});

Configuration​

The configuration of the plugin would be in the form of:

javascript
EventSpecificationsPlugin({
[Plugin integration name]: {
/* Key value pairs of event names and event specification ids */
},
/* More integrations */
});

You can retrieve the configuration for your Event Specifications directly from your Tracking Plan after clicking on the Implement tracking button.

The Media Web data product page in Snowplow Console showing the Event specifications section with an arrow highlighting the "Implement tracking" button, and a list of event specifications including Ad Break End Event, Ad Break Start Event, and Ad Click Event

Was this page helpful?