An injection rule consists in a series of parameters that apply to links in a message in order to collect specific information when the recipient clicks on those links. These parameters that are added to links are used by external systems, such as Google Analytics.
Injection rules are defined by project, not by company. Therefore, each project can have its own set of rules. In addition, the same project can use different rules, based on the target domains. A rule can therefore apply to all communication types in a project, or only to one specific communication type.
It is important to remember that injection rules are only available when clicks are also set to be logged.
Each rule must:
- Be associated to a specific project
- Apply to one or multiple communication types Example Apply this rule only to "Newsletter" type messages
- Apply to a specific domain name Example Apply this rule only to links with domain "dialoginsight.com"
- Include a parameter and its related value
Automatically associate the parameter "utm_medium" to the value "Email" when the link includes "dialoginsight.com".
- So that the link http://www.dialoginsight.com/fr/solutions will be automatically replaced by http://www.dialoginsight.com/fr/solutions?utm_medium=Email
- The website for which statistics are used, Google Analytics, will receive this parameter to identify the source of the visitor; in our example, the source is an email message.
When a rule applies to a communication type, it displays when you open that message, in the message editor, under the Link tracking section, under the Review.
Automatically created Google Analytics rule
By default, a Google Analytics rule is automatically created when a new project is created. This rule is also available for previously created projects when no rules are defined for the project. Although the rule is automatically created, it does not apply by default to messages; you must active it. This activation is performed in the message editor, under > Messages > EMail or under the Review tab.
This Google Analytics rule supports Google Analytics' 3 basic parameters:
- utm_source (where the default value is Openfield)
- utm_medium (where the default value is email)
- utm_campaign (where the default value MUST be defined when activating the rule)
The Google Analytics rule is configured to apply to all links, regardless of their destination. However, if special restrictions need to apply to parameters to inject on some destination sites, you can configure the rule to restrict destination sites.