gtm_create_variable
Create a Google Tag Manager variable by submitting a complete variable JSON resource along with account, container, and workspace IDs. Simplifies adding new variables programmatically.
Instructions
Create a variable from a full GTM Variable resource (JSON string).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account_id": "<account_id>",
"container_id": "<container_id>",
"workspace_id": "<workspace_id>",
"variable_json": "<variable_json>"
},
"name": "gtm_create_variable"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| account_id | Yes | ||
| container_id | Yes | ||
| workspace_id | Yes | ||
| variable_json | Yes |