Skip to main content
Glama

web_vitals

Read-only

Read Core Web Vitals for a project (POST /vitals). p75 is the headline: each metric is assessed at the 75th percentile of page loads, using nearest-rank. Web Vitals is a Pro read. A free account gets 403 PRO_REQUIRED, the same status and error code as POST /query, and that rejection is not metered. Each successful call counts as one metered read.

The event is fixed to page_view. On hosted, vitals are cwv_lcp, cwv_inp, cwv_cls, cwv_fcp, and cwv_ttfb properties on page_view. Collect them by installing the project snippet with data-track-vitals="true".

Thresholds follow web.dev (https://web.dev/articles/vitals) and PageSpeed Insights. LCP: good at or below 2500 ms, poor above 4000 ms. INP: good at or below 200 ms, poor above 500 ms. CLS: good at or below 0.1, poor above 0.25 (unitless). FCP: good at or below 1800 ms, poor above 3000 ms. TTFB: good at or below 800 ms, poor above 1800 ms. A value at or below good_max is good. A value above poor_min is poor. Any value in between is needs-improvement. The same rule rates every page load for the good, needs-improvement, and poor share, and rates the p75.

cwv_pass is true only when the LCP, INP, and CLS p75 ratings are all good. If INP n is 0, the decision uses LCP and CLS only. cwv_pass is null when LCP n is 0 or CLS n is 0. FCP and TTFB do not affect cwv_pass.

group_by is optional. device returns mobile, tablet, and desktop. path returns the top limit paths by sample size, sorted by worst LCP p75. Omit group_by for one site-wide row (group null). limit defaults to 10 and maxes at 20. days, date_from, and date_to select the window. Each metric row includes p75 with its unit, rating, n, skipped, the good/needs-improvement/poor share, and up to 5 top poor targets. FCP and TTFB targets are empty. skipped counts page views that did not report that vital. When the scan hits the 200,000 event cap, approximate is true.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "project": "<project>"
    },
    "name": "web_vitals"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysNoLookback in days. Omit when date_from and date_to are set
limitNoMaximum rows. Defaults to 10 and maxes at 20
date_toNoInclusive end date (YYYY-MM-DD). Optional
projectYesProject name or ID
group_byNoSplit rows by device (mobile, tablet, desktop) or path. Omit for one site-wide row
date_fromNoInclusive start date (YYYY-MM-DD). Optional

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior5/5

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

Annotations already declare a safe read, but the description adds substantial behavior the agent could not otherwise know: Pro-only gating with 403 PRO_REQUIRED, that rejections are unmetered while successes count as one metered read, the 200,000 event cap triggering approximate=true, and precise cwv_pass null/skip logic. This is exactly the value-add expected on top of annotations.

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?

Front-loaded with purpose, access gating, and metering before the metric details, which is the right order. It is long, and the full threshold table for five metrics plus rating rules is dense reference material, but with no output schema most of it earns its place for interpreting results.

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 takes on the burden of explaining returns and does so thoroughly: per-row fields (p75 with unit, rating, n, skipped, share buckets, up to 5 poor targets), which metrics have empty targets, and the cwv_pass decision rule including null conditions. An agent has enough to call and interpret the tool.

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 100%, so the baseline is 3, but the description adds real meaning: device yields mobile/tablet/desktop, path returns top limit paths by sample size sorted by worst LCP p75, and limit defaults to 10 and maxes at 20. That clarifies output shape per parameter choice rather than merely restating the schema.

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?

Opens with a specific verb and resource: 'Read Core Web Vitals for a project', with the endpoint noted. The scope (metrics, event, grouping) is unambiguous. It does not explicitly distinguish itself from sibling analytics tools that might also surface vitals, so it falls just short of 5.

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?

Gives situational guidance for parameters (omit group_by for one site-wide row; use days or date_from/date_to for the window) and states the Pro requirement with the exact 403 PRO_REQUIRED behavior. However, it never says when an agent should reach for this tool instead of siblings like analytics_overview or sessions, so tool-selection guidance is only implied.

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