Guides
Forward UTM Parameters to an Agent
Overview
To forward UTM parameters to your Agent, follow these steps. The UTM parameter name will be listed in the Variables dropdown of your flow. You can declare it in any Variable dropdown, and it will appear in the Results tab once the Agent is launched with the declared UTM parameter.
Steps to Forward UTM Parameters
-
Declare the UTM Parameter Variables:
- Navigate to the Variables dropdown in your Agent flow editor.
- Add the desired UTM parameters as variables, such as
utm_source
andutm_value
.
-
Pass UTM Parameters When Launching the Agent:
- Ensure the Agent is launched with the declared UTM parameters. For example:
- The provided UTM values (
google
andad_campaign
in this example) will be automatically captured and displayed in the Results tab.
- Ensure the Agent is launched with the declared UTM parameters. For example:
-
Save UTM Parameters in Variables:
- When a UTM parameter is included in the Agent’s URL, it will be stored in the corresponding variable (e.g.,
utm_source
).
- When a UTM parameter is included in the Agent’s URL, it will be stored in the corresponding variable (e.g.,
-
Build a Redirect URL:
- Use the saved UTM values to construct a redirect URL in a Redirect Logic Block. For example:
- Use the saved UTM values to construct a redirect URL in a Redirect Logic Block. For example:
Example Redirect Block
Here’s an example of how to build a redirect URL using the UTM variables:
Note: Replace
redirect-site.com
with the appropriate destination URL.
Validation and Testing
Before deployment, ensure:
- All declared UTM parameters are listed correctly in the Variables dropdown.
- The redirect URL dynamically includes the UTM parameters without errors.
- The Agent properly captures and displays UTM parameters in the Results tab.
Use tools like JSONLint to validate JSON structures and Markdownlint to verify the Markdown format.