gtm_container
Perform container operations on Google Tag Manager: create, get, update, remove, list, combine, lookup, moveTagId, and generate snippet.
Instructions
Performs all container-related operations: create, get, update, remove, list, combine, lookup, moveTagId, snippet. The 'list' action returns up to itemsPerPage items per page.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | No | Page number for pagination (starts from 1). Each page contains up to itemsPerPage items. | |
| action | Yes | The container operation to perform. Must be one of: 'create', 'get', 'list', 'update', 'remove', 'combine', 'lookup', 'moveTagId', 'snippet'. | |
| accountId | Yes | The unique ID of the GTM Account containing the container. | |
| containerId | No | The unique ID of the GTM Container. Required for 'get', 'update', 'remove', 'combine', 'lookup', 'moveTagId', and 'snippet' actions. | |
| fingerprint | No | The fingerprint for optimistic concurrency control. Required for 'update' action. | |
| itemsPerPage | No | Number of items to return per page (1-50). Default: 50. Use lower values if experiencing response issues. | |
| combineConfig | No | Configuration for 'combine' action. Specifies which containers to combine. | |
| destinationId | No | The destination ID linked to a GTM Container (e.g., AW-123456789). Required for the 'lookup' action. | |
| moveTagIdConfig | No | Configuration for 'moveTagId' action. Specifies tag ID mapping for moving tags between containers. | |
| createOrUpdateConfig | No | Configuration for 'create' and 'update' actions. All fields correspond to the GTM Container resource. |