Google Tag Manager icon

Google Tag Manager

Use the Google Tag Manager API

Actions84

Overview

The "Revert Client" operation in the Google Tag Manager (GTM) node allows users to revert changes made to a specific GTM Client within a workspace. This is useful when you want to discard local modifications and restore the client entity to its last saved state in the GTM workspace.

Typical scenarios include:

  • Undoing unintended or erroneous edits to a GTM Client configuration.
  • Resetting a client to a known good state before making new changes.
  • Managing version control and collaboration in GTM workspaces by reverting individual clients.

For example, if a user modifies a client but decides not to keep those changes, they can use this operation to revert the client back to its previous version without affecting other entities.

Properties

Name Meaning
Account ID The GTM Account ID where the client resides.
Container ID The GTM Container ID that contains the workspace with the client.
Workspace ID The GTM Workspace ID where the client exists and will be reverted.
Client ID The GTM Client ID of the client to revert.
Optional Query Parameters Additional optional parameters for the API call (e.g., allowUserPermissionFeatureUpdate).

Details on Optional Query Parameters (subset relevant to this operation):

  • allowUserPermissionFeatureUpdate: Boolean flag to allow updating user permission features; must be true to enable certain permission changes.

Output

The output is a JSON object representing the reverted GTM Client resource as returned by the Google Tag Manager API. It reflects the client's state after the revert operation, effectively restoring it to the last saved version in the workspace.

The output JSON structure corresponds to the GTM Client resource schema, typically including fields such as:

  • Client ID
  • Client name and description
  • Configuration details specific to the client
  • Metadata like fingerprint or timestamps

No binary data is involved in this operation.

Dependencies

  • Requires an active and valid OAuth2 credential for Google Tag Manager API access.
  • The node uses the Google Tag Manager API endpoint https://www.googleapis.com/tagmanager/v2.
  • Proper permissions on the GTM account, container, workspace, and client are necessary to perform revert operations.

Troubleshooting

  • Missing Required IDs: Errors will occur if any of the required IDs (Account ID, Container ID, Workspace ID, Client ID) are not provided. Ensure all these inputs are correctly set.
  • Permission Denied: If the OAuth2 credentials lack sufficient permissions, the API call will fail. Verify that the connected Google account has appropriate access rights.
  • Operation Failure Due to User Permission Feature Update: If the optional parameter allowUserPermissionFeatureUpdate is false but the operation requires it to be true, the revert will fail. Set this parameter to true if needed.
  • Unknown Operation Error: If the operation name is incorrect or unsupported, the node will throw an error indicating an unknown operation.
  • API Rate Limits or Quotas: Standard Google API limits apply; hitting these may cause temporary failures.

Links and References


This summary focuses specifically on the "Client" resource and the "Revert Client" operation as requested.

Discussion