Skip to main content
Glama

Li Campaign Analytics

li_campaign_analytics
Read-onlyIdempotent

Analyze campaign performance over a date range (e.g., "2024-01-01" to "2024-01-31"). Returns impressions, clicks, conversions, spend, and CTR by campaign.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
campaign_idsYesArray of campaign IDs to query
date_range_endYesEnd date (YYYY-MM-DD)
date_range_startYesStart date (YYYY-MM-DD)
time_granularityNoGranularity: DAILY, MONTHLY, or ALL (default ALL)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNoError code if connection not found
messageNoError message with guidance
elementsNoAnalytics data by campaign

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "elements": {
      +      "description": "Analytics data by campaign",
      +      "items": {
      +        "properties": {
      +          "clicks": {
      +            "description": "Total clicks",
      +            "type": "number"
      +          },
      +          "conversions": {
      +            "description": "Total conversions",
      +            "type": "number"
      +          },
      +          "ctr": {
      +            "description": "Click-through rate (CTR)",
      +            "type": "number"
      +          },
      +          "impressions": {
      +            "description": "Total impressions",
      +            "type": "number"
      +          },
      +          "pivotValue": {
      +            "description": "Campaign URN or identifier",
      +            "type": "string"
      +          },
      +          "spend": {
      +            "description": "Spend data",
      +            "properties": {
      +              "amount": {
      +                "description": "Spend amount",
      +                "type": "number"
      +              },
      +              "currencyCode": {
      +                "description": "Currency code",
      +                "type": "string"
      +              }
      +            },
      +            "type": "object"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "error": {
      +      "description": "Error code if connection not found",
      +      "type": "string"
      +    },
      +    "message": {
      +      "description": "Error message with guidance",
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "campaign_ids": [
      +      "501234567",
      +      "501234568"
      +    ],
      +    "date_range_end": "2024-01-31",
      +    "date_range_start": "2024-01-01",
      +    "time_granularity": "DAILY"
      +  },
      +  {
      +    "campaign_ids": [
      +      "501234567"
      +    ],
      +    "date_range_end": "2024-12-31",
      +    "date_range_start": "2024-01-01"
      +  }
      +]
  3. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and destructiveHint=False, indicating a safe read operation. The description adds context about the returned metrics and date range format, but does not cover pagination, error handling, or empty result behavior.

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 two sentences long, front-loaded with the action and resource, and every sentence is informative with no superfluous words.

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

Completeness3/5

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

Given the presence of an output schema and rich annotations, the description does not need to detail output format. However, it omits mention of the optional time_granularity parameter and that campaign_ids is an array, relying on examples in the schema. Somewhat incomplete for a full understanding without inspecting the schema.

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?

Schema coverage is 100%, so the schema already describes all parameters. The description mentions 'date range' and 'by campaign' but does not add significant meaning beyond the schema, such as explaining the optional 'time_granularity' parameter or its default value.

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 verb 'analyze' and the resource 'campaign performance' over a date range, listing specific metrics returned (impressions, clicks, conversions, spend, CTR). It distinguishes from sibling tools like 'li_list_campaigns' which list campaigns rather than analyze performance.

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?

The description implies usage for analyzing campaign performance over a date range, but does not explicitly state when to use this tool versus alternatives like li_get_campaign or li_list_campaigns. No prerequisites or exclusions are mentioned.

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.