Actions102
- Account Actions
- Built-In Variable Actions
- Client Actions
- Container Actions
- Destination Actions
- Environment Actions
- Folder Actions
- Google Tag Configuration Actions
- Tag Actions
- Template Actions
- Transformation Actions
- Trigger Actions
- User Permission Actions
- Variable Actions
- Version Actions
- Workspace Actions
- Zone Actions
Overview
This node integrates with the Google Tag Manager (GTM) API, allowing users to manage various GTM resources programmatically. Specifically, for the Destination resource and the Get Destination operation, it retrieves details about a specific destination linked to a GTM container.
Typical use cases include:
- Fetching configuration details of a particular destination within a GTM container.
- Automating retrieval of destination metadata for reporting or synchronization purposes.
- Integrating GTM destination data into broader workflows that involve tag management or analytics setup.
For example, a user might want to get the details of a destination by providing the GTM Account ID, Container ID, and the Destination Link ID to fetch its current configuration or status.
Properties
| Name | Meaning |
|---|---|
| Account ID | The unique identifier of the Google Tag Manager account where the container resides. |
| Container ID | The unique identifier of the GTM container that holds the destination. |
| Destination Link ID | The unique identifier of the Google Tag Destination Link to retrieve. |
| Optional Query Parameters | Additional optional parameters to customize the request. For this operation, typically empty or unused. |
Output
The output is a JSON object representing the retrieved destination's details from the GTM API. This includes all properties and metadata associated with the specified destination link in the container.
The structure corresponds directly to the Google Tag Manager API response for a destination resource, which may include fields such as destination name, type, configuration settings, and linkage information.
No binary data output is involved in this operation.
Dependencies
- Requires an active Google Tag Manager API OAuth2 credential configured in n8n.
- The node makes authenticated HTTP requests to the Google Tag Manager API endpoint:
https://www.googleapis.com/tagmanager/v2. - Proper permissions on the GTM account and container are necessary to access destination details.
Troubleshooting
- Missing Required IDs: If Account ID, Container ID, or Destination Link ID is not provided, the node will throw an error indicating the missing parameter.
- Authentication Errors: Ensure that the Google Tag Manager OAuth2 credentials are correctly set up and authorized.
- API Errors: Errors returned from the GTM API (e.g., permission denied, resource not found) will be surfaced with messages prefixed by "Error calling GTM API".
- Invalid Destination Link ID: Providing an incorrect or non-existent Destination Link ID will result in a not found error from the API.
To resolve these issues:
- Double-check all required input parameters.
- Verify OAuth2 credentials and scopes.
- Confirm the existence and correctness of the Destination Link ID in the GTM container.