Skip to main content
Glama

mureo_state_platform_metrics_set

Atomically update platform-level metric rollups in STATE.json to render per-platform KPIs and period toggles without re-querying, while preserving campaigns and merging per-window data.

Instructions

Atomically set a platform's metric ROLLUP in STATE.json's v2 platforms section so the read-only reporting dashboard can render per-platform KPIs (and the YESTERDAY / LAST_30_DAYS period toggle) without re-querying. This writes the PLATFORM-LEVEL rollup — distinct from mureo_state_upsert_campaign, which writes per-campaign metrics. Pass totals + metrics_period for the single most-recent window, and/or periods ({"YESTERDAY": {…}, "LAST_30_DAYS": {…}}) for the per-window rollups the toggle reads. periods is merged per window key (a YESTERDAY write keeps a prior LAST_30_DAYS bucket); omitted fields preserve their existing value. Campaigns and every other platform are preserved. account_id is required and always written onto the entry. Returns the updated state document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoOptional path to the file. Defaults to STRATEGY.md / STATE.json in the MCP server's current working directory. Paths outside cwd are refused.
totalsNoSingle-rollup totals for the most recent window (spend, impressions, clicks, conversions, cpa, ctr, result_indicator, period, fetched_at). Omit to preserve the existing value.
periodsNoPer-window rollups keyed by period token (``YESTERDAY`` / ``LAST_30_DAYS`` / …); each value is a totals-shaped object. Merged per key into the existing map. Omit to preserve the existing map.
platformYesPlatform key: a built-in (``google_ads`` / ``meta_ads`` / ``tiktok_ads`` / ``search_console`` / ``ga4``) or a plugin bridge ``plugin:<dist>``. Use the SAME key the account is already stored under — one ad account has exactly one platform key, and a second key for an account another key already holds is REJECTED (the reporting view sums the entries, so it would double-count).
account_idYesThe platform account id (Google customer_id / Meta act_*). Always written onto the platform entry, and used to detect a second entry for the same account.
metrics_periodNoThe window ``totals`` covers (e.g. ``LAST_30_DAYS``). Omit to preserve the existing value.
Behavior5/5

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

With no annotations provided, the description carries full behavioral disclosure. It covers atomicity, merging per window key, preservation of omitted fields and other platforms/campaigns, the always-written account_id, and return of the updated state document. This is comprehensive for a mutation tool.

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

Conciseness5/5

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

The description is a single dense paragraph that is well-structured and front-loaded. Every sentence adds value: purpose, differentiation, parameter guidance, merge behavior, and return value. No fluff or repetition.

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 a tool with nested objects and no output schema, the description fully covers what the tool does, how parameters interact, side effects, and return value. It also explains the functional context (read-only dashboard toggle), making it complete for an AI agent.

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

Parameters5/5

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

Even though schema coverage is 100%, the description adds crucial meaning: it explains the relationship between totals/metrics_period and periods, merge semantics with a concrete YESTERDAY/LAST_30_DAYS example, and the platform key uniqueness rule. This significantly clarifies parameter usage beyond the schema.

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?

The description clearly states the tool atomically sets a platform-level metric rollup in STATE.json's v2 platforms section. It explicitly distinguishes itself from mureo_state_upsert_campaign, which writes per-campaign metrics, making the purpose unmistakable.

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?

It explains the tool is for feeding the read-only reporting dashboard's per-platform KPIs and period toggle without re-querying. It explicitly names the alternative tool (mureo_state_upsert_campaign) and contrasts when each should be used, plus detailed guidance on totals vs periods parameters.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/logly/mureo'

If you have feedback or need assistance with the MCP directory API, please join our Discord server