Skip to main content
Glama

Draft an Analytics annotation

draft_ga4_annotation
Destructive

Draft creating, changing or deleting a GA4 annotation (a note on a date or date range in GA4's charts), returning a PREVIEW.

Use it to mark what explains a change in the data: a site relaunch, a price change, a campaign start, a tracking fix. Create needs title and date; update and delete need the annotation's ID from list_ga4_annotations, and an update changes only the fields passed (the preview shows before and after). Annotations Google created itself cannot be changed. Nothing changes until confirm_and_apply applies it; the dry run re-reads the annotation and refuses if it was changed in GA4 after the preview. GA4 Admin API v1alpha (reportingDataAnnotations).

Google Analytics Data API: https://developers.google.com/analytics/devguides/reporting/data/v1 and Admin API: https://developers.google.com/analytics/devguides/config/admin/v1

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "draft_ga4_annotation"
  }
}

Input Schema

NameRequiredDescriptionDefault
dateNoThe day as YYYY-MM-DD, or the first day of a range together with end_date. Required for create.
colorNoBLUE (default on create), GREEN, RED, PURPLE, BROWN or CYAN.
titleNoUp to 60 characters. Required for create.
actionNo"create" (default), "update" or "delete".create
end_dateNoLast day of a range (YYYY-MM-DD); leave empty for one day.
annotationNoID or resource name of the annotation to update or delete (list_ga4_annotations).
descriptionNoUp to 150 characters. On update, "" clears it.
property_idNoNumeric GA4 property ID, with or without the "properties/" prefix. If empty, uses the default from config.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations declare destructiveHint=true and openWorldHint=true; the description goes further by explaining that nothing mutates until confirm_and_apply, that updates are partial (only fields passed change, preview shows before/after), that Google-created annotations are immutable, and that the dry run re-reads and refuses stale previews. That optimistic-concurrency detail is genuinely valuable. It does not describe the preview payload shape, though an output schema exists, so the gap is minor.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the most important fact (returns a PREVIEW, nothing changes until confirm_and_apply) and stays dense with actionable detail. The trailing Google API documentation URLs and the API-version parenthetical are boilerplate that does not help tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter mutation tool with branching action semantics, the description covers prerequisites, mutation scope, immutability constraints, concurrency safety, and the handoff to confirm_and_apply. With an output schema present, no explanation of return values is needed, so nothing material is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, but the description adds conditional semantics the schema cannot express: which parameters are effectively required per action value, that the annotation ID comes from list_ga4_annotations, and that an update is partial. It stops short of explaining color/description defaults per action, which would have made it a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('draft creating, changing or deleting a GA4 annotation'), defines the resource inline ('a note on a date or date range in GA4's charts'), and makes the preview-only nature explicit. It is clearly distinguishable from list_ga4_annotations (read) and confirm_and_apply (apply).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete use cases ('mark what explains a change in the data: a site relaunch, a price change, a campaign start, a tracking fix'), per-action prerequisites (create needs title and date; update/delete need the ID from list_ga4_annotations), and names the downstream tool confirm_and_apply as the apply step. Both the when and the what-next are explicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.