Zum Inhalt

MCP

Google Tag Manager MCPTool-Dokumentation

23 Tool Calls, ihre Eingaben und die Grenzen dieser Verbindung. Stand der Implementierung: 8. Oktober 2026.

Die vollständige Tool-Referenz.

11 Lese-Tools und 12 Schreib-Tools. Öffne ein Tool für Parameter und vollständiges JSON Schema. Unbekannte Felder werden abgelehnt.

gtm_list_containersFreigegebene Container auflisten
Lesen

Liefert nur die für diese Verbindung ausgewählten Container.

Eingabeparameter

Keine Parameter. Übergib ein leeres Objekt: {}.

Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
gtm_get_containerContainer lesen
Lesen

Liest die Konfiguration eines ausgewählten Containers.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key"
  ],
  "additionalProperties": false
}
gtm_list_workspacesWorkspaces auflisten
Lesen

Liest eine Seite der Workspaces im ausgewählten Container; weitere Seiten über page_token.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
page_tokenOptional
string · Max. Zeichen: 4096
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "page_token": {
      "type": "string",
      "maxLength": 4096
    }
  },
  "required": [
    "resource_key"
  ],
  "additionalProperties": false
}
gtm_get_workspaceWorkspace lesen
Lesen

Liest einen Workspace einschließlich seines aktuellen Fingerprints.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key",
    "workspace_id"
  ],
  "additionalProperties": false
}
gtm_get_workspace_statusWorkspace-Änderungen prüfen
Lesen

Liest geänderte und konfliktbehaftete Elemente. Synchronisiert, versioniert und veröffentlicht den Container nicht.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key",
    "workspace_id"
  ],
  "additionalProperties": false
}
gtm_create_workspaceWorkspace anlegen
Ändern

Erstellt einen unveröffentlichten Workspace. Benötigt einen ausdrücklichen Auftrag und eine eindeutige operation_id.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
operation_idPflichtfeld
string · uuid
namePflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 256
descriptionOptional
string · Max. Zeichen: 2000
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 256
    },
    "description": {
      "type": "string",
      "maxLength": 2000
    }
  },
  "required": [
    "resource_key",
    "operation_id",
    "name"
  ],
  "additionalProperties": false
}
gtm_update_workspaceWorkspace ändern
Ändern

Liest den Workspace frisch ein und ändert Name/Beschreibung mit atomarer Fingerprint-Prüfung. Nicht übergebene Felder bleiben erhalten. Veröffentlicht den Container nicht.

Frischer Lesezugriff vor der Änderung: gtm_get_workspace.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
namePflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 256
descriptionOptional
string · Max. Zeichen: 2000
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 256
    },
    "description": {
      "type": "string",
      "maxLength": 2000
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "operation_id",
    "fingerprint",
    "name"
  ],
  "additionalProperties": false
}
gtm_delete_workspaceWorkspace entfernen
Ändern

Löscht den Workspace mit seinen unveröffentlichten Änderungen nach frischer Fingerprint-Prüfung. Google DELETE prüft den Fingerprint nicht atomar; parallele Änderungen können dazwischenliegen. Veröffentlicht den Container nicht.

Ändert bestehende Konfiguration oder den Kampagnenstatus. Ein ausdrücklicher Nutzerauftrag ist erforderlich.

Frischer Lesezugriff vor der Änderung: gtm_get_workspace.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "operation_id",
    "fingerprint"
  ],
  "additionalProperties": false
}
gtm_list_tagsTags auflisten
Lesen

Liest eine Seite der Tags im Workspace; weitere Seiten über page_token.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
page_tokenOptional
string · Max. Zeichen: 4096
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "page_token": {
      "type": "string",
      "maxLength": 4096
    }
  },
  "required": [
    "resource_key",
    "workspace_id"
  ],
  "additionalProperties": false
}
gtm_get_tagTag lesen
Lesen

Liest ein Workspace-Element einschließlich seines aktuellen Fingerprints.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id"
  ],
  "additionalProperties": false
}
gtm_create_tagTag anlegen
Ändern

Erstellt ein unveröffentlichtes Workspace-Element mit dem im Schema beschriebenen body. Benötigt einen ausdrücklichen Auftrag; veröffentlicht den Container nicht.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "firingTriggerId": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "type": "string",
            "maxLength": 40,
            "pattern": "^[1-9]\\d*$"
          }
        },
        "blockingTriggerId": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "type": "string",
            "maxLength": 40,
            "pattern": "^[1-9]\\d*$"
          }
        },
        "paused": {
          "type": "boolean"
        },
        "tagFiringOption": {
          "type": "string",
          "enum": [
            "unlimited",
            "oncePerEvent",
            "oncePerLoad"
          ]
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "operation_id",
    "body"
  ],
  "additionalProperties": false
}
gtm_update_tagTag ändern
Ändern

Liest das Element frisch ein, erhält andere Felder und wendet Änderungen mit atomarer Fingerprint-Prüfung an. body benötigt name und type. Veröffentlicht den Container nicht.

Frischer Lesezugriff vor der Änderung: gtm_get_tag.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "firingTriggerId": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "type": "string",
            "maxLength": 40,
            "pattern": "^[1-9]\\d*$"
          }
        },
        "blockingTriggerId": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "type": "string",
            "maxLength": 40,
            "pattern": "^[1-9]\\d*$"
          }
        },
        "paused": {
          "type": "boolean"
        },
        "tagFiringOption": {
          "type": "string",
          "enum": [
            "unlimited",
            "oncePerEvent",
            "oncePerLoad"
          ]
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint",
    "body"
  ],
  "additionalProperties": false
}
gtm_delete_tagTag entfernen
Ändern

Entfernt ein unveröffentlichtes Workspace-Element nach frischer Fingerprint-Prüfung. Google DELETE prüft nicht atomar; parallele Änderungen können dazwischenliegen. Veröffentlicht den Container nicht.

Ändert bestehende Konfiguration oder den Kampagnenstatus. Ein ausdrücklicher Nutzerauftrag ist erforderlich.

Frischer Lesezugriff vor der Änderung: gtm_get_tag.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint"
  ],
  "additionalProperties": false
}
gtm_list_triggersTrigger auflisten
Lesen

Liest eine Seite der Trigger im Workspace; weitere Seiten über page_token.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
page_tokenOptional
string · Max. Zeichen: 4096
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "page_token": {
      "type": "string",
      "maxLength": 4096
    }
  },
  "required": [
    "resource_key",
    "workspace_id"
  ],
  "additionalProperties": false
}
gtm_get_triggerTrigger lesen
Lesen

Liest ein Workspace-Element einschließlich seines aktuellen Fingerprints.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id"
  ],
  "additionalProperties": false
}
gtm_create_triggerTrigger anlegen
Ändern

Erstellt ein unveröffentlichtes Workspace-Element mit dem im Schema beschriebenen body. Benötigt einen ausdrücklichen Auftrag; veröffentlicht den Container nicht.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "customEventFilter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        },
        "filter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        },
        "autoEventFilter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "operation_id",
    "body"
  ],
  "additionalProperties": false
}
gtm_update_triggerTrigger ändern
Ändern

Liest das Element frisch ein, erhält andere Felder und wendet Änderungen mit atomarer Fingerprint-Prüfung an. body benötigt name und type. Veröffentlicht den Container nicht.

Frischer Lesezugriff vor der Änderung: gtm_get_trigger.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "customEventFilter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        },
        "filter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        },
        "autoEventFilter": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "equals",
                  "contains",
                  "startsWith",
                  "endsWith",
                  "matchRegex",
                  "greater",
                  "greaterOrEquals",
                  "less",
                  "lessOrEquals",
                  "cssSelector",
                  "urlMatches"
                ]
              },
              "parameter": {
                "maxItems": 10,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "template",
                        "integer",
                        "boolean",
                        "tagReference"
                      ]
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 8000
                    }
                  },
                  "required": [
                    "type",
                    "value"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "type",
              "parameter"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint",
    "body"
  ],
  "additionalProperties": false
}
gtm_delete_triggerTrigger entfernen
Ändern

Entfernt ein unveröffentlichtes Workspace-Element nach frischer Fingerprint-Prüfung. Google DELETE prüft nicht atomar; parallele Änderungen können dazwischenliegen. Veröffentlicht den Container nicht.

Ändert bestehende Konfiguration oder den Kampagnenstatus. Ein ausdrücklicher Nutzerauftrag ist erforderlich.

Frischer Lesezugriff vor der Änderung: gtm_get_trigger.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint"
  ],
  "additionalProperties": false
}
gtm_list_variablesVariablen auflisten
Lesen

Liest eine Seite der Variablen im Workspace; weitere Seiten über page_token.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
page_tokenOptional
string · Max. Zeichen: 4096
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "page_token": {
      "type": "string",
      "maxLength": 4096
    }
  },
  "required": [
    "resource_key",
    "workspace_id"
  ],
  "additionalProperties": false
}
gtm_get_variableVariable lesen
Lesen

Liest ein Workspace-Element einschließlich seines aktuellen Fingerprints.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id"
  ],
  "additionalProperties": false
}
gtm_create_variableVariable anlegen
Ändern

Erstellt ein unveröffentlichtes Workspace-Element mit dem im Schema beschriebenen body. Benötigt einen ausdrücklichen Auftrag; veröffentlicht den Container nicht.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "operation_id",
    "body"
  ],
  "additionalProperties": false
}
gtm_update_variableVariable ändern
Ändern

Liest das Element frisch ein, erhält andere Felder und wendet Änderungen mit atomarer Fingerprint-Prüfung an. body benötigt name und type. Veröffentlicht den Container nicht.

Frischer Lesezugriff vor der Änderung: gtm_get_variable.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
bodyPflichtfeld
object · Pflicht im Objekt: name, type
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "body": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 256
        },
        "type": {
          "type": "string",
          "maxLength": 100,
          "pattern": "^[A-Za-z0-9_]+$"
        },
        "notes": {
          "type": "string",
          "maxLength": 2000
        },
        "parameter": {
          "maxItems": 100,
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "template",
                      "integer",
                      "boolean",
                      "tagReference"
                    ]
                  },
                  "value": {
                    "type": "string",
                    "maxLength": 8000
                  }
                },
                "required": [
                  "type",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "list"
                  },
                  "list": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "list"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "type": {
                    "type": "string",
                    "const": "map"
                  },
                  "map": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "template",
                            "integer",
                            "boolean",
                            "tagReference"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "maxLength": 8000
                        }
                      },
                      "required": [
                        "type",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "type",
                  "map"
                ],
                "additionalProperties": false
              }
            ]
          }
        }
      },
      "required": [
        "name",
        "type"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint",
    "body"
  ],
  "additionalProperties": false
}
gtm_delete_variableVariable entfernen
Ändern

Entfernt ein unveröffentlichtes Workspace-Element nach frischer Fingerprint-Prüfung. Google DELETE prüft nicht atomar; parallele Änderungen können dazwischenliegen. Veröffentlicht den Container nicht.

Ändert bestehende Konfiguration oder den Kampagnenstatus. Ein ausdrücklicher Nutzerauftrag ist erforderlich.

Frischer Lesezugriff vor der Änderung: gtm_get_variable.

Eingabeparameter

resource_keyPflichtfeld
string · Max. Zeichen: 200
workspace_idPflichtfeld
string · Max. Zeichen: 40
entity_idPflichtfeld
string · Max. Zeichen: 40
operation_idPflichtfeld
string · uuid
fingerprintPflichtfeld
string · Min. Zeichen: 1 · Max. Zeichen: 200
Vollständiges Eingabeschema (JSON)
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "resource_key": {
      "type": "string",
      "maxLength": 200,
      "pattern": "^accounts\\/[1-9]\\d*\\/containers\\/[1-9]\\d*$"
    },
    "workspace_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "entity_id": {
      "type": "string",
      "maxLength": 40,
      "pattern": "^[1-9]\\d*$"
    },
    "operation_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "description": "Unique operation ID. Reuse only to retrieve this exact operation status; never reuse for changed arguments."
    },
    "fingerprint": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    }
  },
  "required": [
    "resource_key",
    "workspace_id",
    "entity_id",
    "operation_id",
    "fingerprint"
  ],
  "additionalProperties": false
}

Ein konkreter Tool Call.

JSON-RPC-Aufruf nach der MCP-Initialisierung. Beispiel-IDs und Datumswerte: Ersetze sie durch deine ausgewählte Ressource und deinen Berichtszeitraum. Der KI-Client übernimmt Transport und Autorisierung.

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "gtm_list_tags",
    "arguments": {
      "resource_key": "accounts/123456/containers/789012",
      "workspace_id": "1"
    }
  }
}

So kommen Ergebnisse zurück.

structuredContent
Enthält das Tool-Ergebnis als JSON-Objekt. Google-Feldnamen bleiben erhalten. Dasselbe JSON wird zusätzlich als Textblock in content zurückgegeben.
Daten je Tool
Workspace- und Element-Abfragen liefern die Google-Konfiguration mit path und fingerprint. Listen können nextPageToken enthalten. Workspace-Status beschreibt Änderungen/Konflikte. Löschung liefert status: removed und resource_name.
Ausgewählte Ressourcen
Das erste Listen-Tool liefert resources mit resource_key. Es listet ausschließlich die für diese Verbindung freigegebenen Ressourcen.
isError: true
Tool-Fehler liefern structuredContent.error und request_id, optional retry_after_seconds. Beispiele: scope_missing bei fehlendem Zugriff oder service_unavailable bei einem nicht erreichbaren Dienst. Einen unsicheren Schreibauftrag nicht blind wiederholen.

Zugriff und technische Grenzen.

Änderungen betreffen unveröffentlichte Workspaces. Es gibt keinen Publish-, Sync- oder Versionierungs-Call. Updates und Löschungen benötigen den aktuellen fingerprint. Der Server liest vorher frisch; dieser zusätzliche Lesezugriff benötigt eigene Freigabe und Quota. Updates prüfen atomar bei Google; DELETE kann trotz Vorprüfung mit einer parallelen Änderung kollidieren. body ist begrenzt und benötigt name und type. Verschachtelte Parameter stehen im vollständigen Eingabeschema. Veröffentlichung separat in Google Tag Manager prüfen und durchführen.

Die Verbindung verwendet MCP Streamable HTTP mit Bearer-Autorisierung. Der Server prüft Lese-/Schreibrechte und die ausgewählte Ressource bei jedem Call. Sowohl deine Google-Berechtigungen als auch die Zugriffsrechte deiner MCP-Verbindung müssen die Aktion erlauben. Clients entdecken Tools über tools/list; diese Seiten dokumentieren das Tool-Verzeichnis.

Lese-Scope: mcp:gtm:read. Schreib-Scope: mcp:gtm:write.

Jeder Schreibzugriff benötigt eine UUID als operation_id. Verwende sie nur für exakt dieselbe Aktion erneut, niemals mit geänderten Argumenten. Eine bereits abgeschlossene Aktion liefert beim erneuten Aufruf mutation_status: succeeded und replayed: true, optional result_ref, statt der ursprünglichen Google-Antwort. Schreibzugriffe werden nicht automatisch wiederholt.