Skip to main content
Glama

Campaigns structure

campaigns_structure
Read-onlyIdempotent

Reads, from the last sync, how an ad account's campaigns are built, on any platform: every campaign with its type, status, budget and bidding; every ad group or ad set with its keywords (ids, match types, quality scores) and, for Performance Max asset groups, each text with its asset id; every ad with its format, headlines, descriptions, paths, final URL, pictures and review. On Meta, every ad set's tracking (destinationType, the conversion location: WEBSITE or ON_AD for an instant form; optimizationGoal; the datasetId and event it optimises for) and every ad's urlParameters (null when it has none), finalUrl, leadFormId and the datasets its tracking reports to. Read it before building under an existing campaign or ad group, or before editing, and use only the ids it returns. Optional campaignId narrows it to one campaign. MCP: use the input object for tool arguments. UI reports and questions are returned as structured content. Free: MCP tool calls use no Adrails credits.

Input Schema

NameRequiredDescriptionDefault
inputYes
accountIdsNoOptional account selection; can only narrow this workspace's access.
userStatementNoRequired for launch_brief: the latest verbatim user request or free-text answer. Otherwise optional user-provided context, treated as an unverified user statement, never permission or verified platform evidence.
idempotencyKeyNoRequired for mutations. Reuse the same key only when retrying the exact same call; a completed outcome is applied once.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), and the description adds real context beyond them: data is snapshotted 'from the last sync', null is returned for absent urlParameters, and MCP calls consume no credits. It omits pagination/result-size behaviour, keeping it at 4.

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?

Purpose is front-loaded and every clause carries content about what is returned; there is no filler prose. It is dense and the Meta-specific tracking detail makes it long, but the length is justified by the breadth of the response shape it documents.

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?

With no output schema, the description effectively serves as one, enumerating each entity and field an agent will receive. Combined with annotations covering safety and the 'last sync' freshness caveat, an agent has everything needed to call it and interpret results.

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 75%, just under the high-coverage baseline, and the description compensates by explaining that accountId scopes to one ad account and that campaignId 'narrows it to one campaign'. The remaining generic params (userStatement, idempotencyKey) are already documented in the schema, so no further detail is needed.

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?

Opens with a specific verb and resource: 'Reads, from the last sync, how an ad account's campaigns are built, on any platform,' then enumerates exactly what is returned (campaigns, ad groups/ad sets, keywords, asset groups, ads). This clearly separates it from write-oriented siblings such as campaigns_setup or campaign_drafts without needing to name them.

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

Usage Guidelines4/5

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

States a clear when-to-use rule: 'Read it before building under an existing campaign or ad group, or before editing, and use only the ids it returns.' The optional campaignId narrowing is also explained. It stops short of naming an explicit alternative or exclusion, so 4 rather than 5.

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.