Skip to main content
Glama

ga4_data_retention

Check how long GA4 retains event-level and user-level data for explorations by retrieving the property's retention settings.

Instructions

How long GA4 keeps event-level and user-level data for explorations. Requires: Google Analytics Admin API (analyticsadmin.googleapis.com) enabled on the quota project; Lector (Viewer) en la propiedad de GA4. If it fails for access, the error explains how to fix it; ga4_check_access checks everything at once.

Input Schema

NameRequiredDescriptionDefault
propertyNoSaved property name (see ga4_list_properties). Defaults to the default property.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.1.0

TDQS

B3.4/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It usefully discloses prerequisites (Admin API enabled on the quota project, Viewer role on the GA4 property) and error behavior ('the error explains how to fix it'), but it never explicitly states the call is read-only/non-mutating and says nothing about the response shape or the possible retention values.

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

Conciseness3/5

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

The purpose is front-loaded and the sentence count is low, but the remainder is a run-on semicolon chain and switches mid-sentence into Spanish ('Lector (Viewer) en la propiedad de GA4'), which adds friction for an agent parsing the requirements.

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

Completeness4/5

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

For a simple single-optional-parameter read with no output schema, the description covers purpose, prerequisites, and failure recovery adequately. The main missing piece is any hint about the returned retention settings (e.g., preset periods), which would help since no output schema exists.

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

Parameters3/5

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

The single 'property' parameter is fully documented in the schema (100% coverage), including that it is a saved property name and defaults to the default property. The description adds no further meaning beyond that, which is acceptable given the schema does the work.

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

Purpose4/5

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

The description states a specific resource and what information is returned: how long GA4 retains event-level and user-level data for explorations. It is clearly distinguishable from reporting siblings, though the verb is implicit (a read of retention settings) rather than stated outright.

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

Usage Guidelines3/5

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

It names ga4_check_access as the tool that 'checks everything at once', which implies routing for access verification, and it lists the prerequisites that must hold before calling. However, it never states when to call this tool rather than ga4_property_details or another configuration reader, so usage is only implied.

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