Skip to main content
Glama

devtune_get_ai_referrals

Read-onlyIdempotent

Get complete paginated AI-referral landing pages (including engagement and page value), overview, and the complete engines breakdown with selected-provider sessions, distinct selected conversions, provider provenance, coverage gaps and native metrics for the same fixed window. Selected conversion events with no site visit, such as server-sent events, are reported as noSiteVisitOccurrences and are not coverage gaps. conversionDefinitions gives, per selected PostHog event or action that occurred in the same window (ones with no occurrences are omitted), occurrences with no site visit and occurrences tied to a site visit, with windowComplete; one with no site-visit occurrences in a complete window cannot be credited to AI. GA4 key events are omitted because they are always session-scoped. Also returns visitorShare: AI-referral sessions over all sessions from the selected analytics provider for the same window (0 to 1), whenever the provider imported every day and recorded sessions. Sessions that may be AI referrals but could not be traced (unknown source or site) are not counted as AI; unattributedSessions counts them and partial is true when there are any; priorShare appears only when both windows have a share, with priorPartial. With no provider, a day not imported or no sessions, the share is null with a reason, never 0. Also returns pageComparison: for each landing page in this page of results, engagement, bounce and conversion rates for AI-referral sessions against every other session on the same page over the same window. Rates appear only when status is compared, meaning the provider imported every day, no AI-referral session that could belong to the page is untraced, at most 2% of the page's other traffic is untraced (untracedShare gives the share on every compared page), and both sides have minimumSessions; otherwise reason says why (incomplete_import, needs_reauth, incomplete_attribution, too_few_ai_sessions, too_few_other_sessions). A compared page with no conversion rate has conversionReason no_key_events or incomplete_attribution. gap names a project-level gap (no_source, disconnected, needs_reauth, incomplete_import, no_key_events). Conversions with no site visit are left out of both sides and counted in noSiteVisitConversions. Sessions are not people; conversion rates are events per session. Missing provider measurements remain null.

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": "devtune_get_ai_referrals"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoThe same setting as pageSize. Send either.
cursorNoOpaque cursor from the previous response; cursors expire after ~48 hours.
pageSizeNoResults per page (1-100). Defaults to 25.
windowDaysNoFixed rolling window in days: 7, 30, or 90. Defaults to 30.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changed
    • removedInput schema / additionalProperties
      Removed value: -false
    • removedInput schema / properties / limit / $ref
      Removed value: -"#/properties/pageSize"
    • addedInput schema / properties / limit / maximum
      Added value: +100
    • addedInput schema / properties / limit / minimum
      Added value: +1
    • addedInput schema / properties / limit / type
      Added value: +"integer"
    • changedInput schema / properties / windowDays / anyOf
      Previous value: -[
      -  {
      -    "enum": [
      -      "7",
      -      "30",
      -      "90"
      -    ],
      -    "type": "string"
      -  },
      -  {
      -    "enum": [
      -      7,
      -      30,
      -      90
      -    ],
      -    "type": "number"
      -  }
      -]New value: +[
      +  {
      +    "enum": [
      +      "7",
      +      "30",
      +      "90"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "anyOf": [
      +      {
      +        "const": 7,
      +        "type": "number"
      +      },
      +      {
      +        "const": 30,
      +        "type": "number"
      +      },
      +      {
      +        "const": 90,
      +        "type": "number"
      +      }
      +    ]
      +  }
      +]
  2. Changed1 schema field changed
    • addedInput schema / properties / cursor / maxLength
      Added value: +12288
  3. Changed1 schema field changed
    • addedInput schema / properties / limit
      Added value: +{
      +  "$ref": "#/properties/pageSize",
      +  "description": "The same setting as pageSize. Send either."
      +}
  4. First observed

TDQS

B3.2/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, and closed-world, so the description is not obligated to cover safety. It nonetheless adds substantial behavioral context that annotations cannot: null is returned with a reason rather than 0, comparisons only appear when status is 'compared' with an enumerated set of blocking reasons, and coverage gaps such as noSiteVisitOccurrences are explicitly excluded from gap counting. That is meaningful disclosure of how incomplete or partial data will surface.

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

Conciseness2/5

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

The definition is a single run-on paragraph of several hundred words mixing pagination, conversion definitions, share semantics, comparison gating rules, and gap codes with no headings, lists, or ordering. Only the first clause is front-loaded; the rest is a dense stream an agent must parse in one pass. Length is driven by under-structuring rather than by unnecessary information.

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?

With no output schema, the description carries the return contract and does explain nullability, reason codes, and exclusion rules in detail. However it never specifies what the 'overview' or the engine breakdown actually contain, nor which project/account scope is queried, so an agent cannot fully predict the response. Dense but with real holes.

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 description coverage is 100%, with every one of the four parameters (limit, pageSize, windowDays, cursor) documented inline including defaults, ranges, and cursor expiry. The description adds no parameter-level detail such as how windowDays affects the breakdown or what cursor pagination yields per page. Baseline 3 applies when the schema does the heavy lifting.

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 opening clause names a specific verb and resource set: 'Get complete paginated AI-referral landing pages (including engagement and page value), overview, and the complete engines breakdown.' That is far more specific than a tautology and lets an agent know this is an AI-referral traffic report. It does not differentiate itself from any sibling tool, so it falls short of a 5.

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

Usage Guidelines2/5

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

There is no when-to-use guidance, no prerequisites, and no named alternative among the many sibling analytics tools. The description only says what the response contains, leaving the agent to infer that this tool is selected whenever AI-referral analysis is wanted. Conditions like 'with no provider... the share is null' describe output states, not invocation guidance.

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.

Resources