Vercel Analytics in Claude, Cursor and your own code
Lookout gives every workspace a read-only API, an MCP server and webhooks, so the numbers on your boards can be asked about, pulled and pushed, not only looked at.
Last updated October 21, 2026
Why an API when Vercel has one?
Vercel’s Web Analytics API returns one project at a time and needs a Vercel token with access to the whole team. Lookout already reads it for you and keeps the results together: boards, previous-period comparisons, goals, campaigns, alerts. The Lookout API exposes that layer, so a script or an AI assistant gets “every landing page on the Acme board, with the change against last week” in one call, using a key that only sees your workspace and, unless you allow it, can only read.
Three ways in
- MCP server. Connect Claude, Cursor or Claude Code and ask questions in plain language. The assistant calls Lookout tools such as
get_boardorcompare_sitesand answers with your real data. The server is open source (MIT): lookout-mcp on GitHub. - REST API. JSON for the same numbers the dashboard shows, for Google Sheets, Notion, n8n or your own backend.
- Webhooks. Lookout sends a signed POST when an alert fires, a site spikes or drops, a digest or report goes out, a new project without Web Analytics appears, or a project turns Analytics on. Slack and Discord incoming-webhook URLs work as they are.
Keys
- Open Settings → API & MCP and create a key. Give it a name that says what will use it, for example “Notion dashboard”. Only workspace owners can create keys; members can’t.
- Copy it once. Lookout shows the full key one time and keeps only a hash. If you lose it, revoke it and create another.
- Use it as a bearer token. A key is read-only unless you tick Allow notes and exports when you create it. Every key is scoped to its workspace and limited to 600 requests an hour. Over the limit you get a
429with aRetry-Afterheader.
Revoking a key takes effect on the next request, including for MCP clients configured with it. The list shows when each key was last used, so unused keys are easy to spot.
Setting up MCP
The server speaks Streamable HTTP at mcp.lookoutstats.com and uses your API key as a bearer token. Paste the configuration for your client, replace the key, and restart it.
{
"mcpServers": {
"lookout": {
"url": "https://mcp.lookoutstats.com",
"headers": {
"Authorization": "Bearer lk_live_your_key_here"
}
}
}
}Claude Desktop: Settings → Developer → Edit config. On claude.ai: Settings → Connectors → Add custom connector, with the same URL and key.
Once connected, the assistant has these tools:
| Tool | What it returns |
|---|---|
list_boards | The workspace’s boards with their site counts. |
get_board | Every site on a board for a range: visitors, page views, pages per visit, change against the previous period, top referrer and country, conversions. |
get_flow | Traffic between a board’s sites: which site sends visitors to which, and how many. |
get_site | One site in depth: daily series, referrers, countries, pages, deployments and notes. |
compare_sites | Up to five sites side by side, absolute, indexed to 100 or against a baseline. |
get_campaigns | UTM source, medium and campaign breakdown for a site. |
list_alerts | Alert rules and what fired recently. |
add_annotation | Pins a note to a date on a board, for every site on it or one site (write). |
export_board | Makes a PDF or CSV of a board and returns a download link that works for 5 minutes (write). |
Read tools never change anything. The two write tools, add_annotation and export_board, need a key created with Allow notes and exports. They do what the buttons in the app do: a note shows on the board’s charts like any other, and an export is the same file the Export button makes. Try asking: “Which landing page dropped most this week, and what deployed right before?” or “Compare the three pricing pages over the last 30 days, indexed.”
The REST API
Reads are GET and work with any key; adding a note and making an export link are POST and need a key with Allow notes and exports. Reads take the same range values as the app (24h, 7d, 30d, or a custom range of up to 30 days written 2026-10-01..2026-10-14) and return the previous period alongside, so a change percentage never has to be computed on your side.
| Endpoint | Returns |
|---|---|
/v1/boards | Boards in the workspace. |
/v1/boards/{id}/sites | Sites on a board with visitors, page views, pages per visit, change, top referrer and country, conversions. |
/v1/boards/{id}/flow | Traffic between a board’s sites: hops from one site to another, with visitors. |
/v1/boards/{id}/scorecard | A grade (A–D) per landing page, against the board’s others: trend, pages per visit, conversion, Core Web Vitals, visitors sent onward. |
/v1/boards/{id}/annotations | The board’s notes; with a write key, POST adds one. A board can be named by its id or its exact name. |
/v1/boards/{id}/export | POST, with a write key: a PDF or CSV download link that works for 5 minutes. |
/v1/sites/{id} | The site and its Core Web Vitals. |
/v1/sites/{id}/overview | One site in depth in one request: series, sources, countries, pages, deployments, Core Web Vitals and, with a board, its notes. |
/v1/sites/{id}/series | Daily (or hourly for 24h) visitors and page views, with the previous period. |
/v1/sites/{id}/breakdowns | Top referrers, countries and pages. |
/v1/sites/{id}/deployments | Production deployments in the range, newest first. |
/v1/sites/{id}/speed | Core Web Vitals for all, mobile or desktop visitors, and the slowest routes. |
/v1/sites/{id}/campaigns | UTM breakdown. |
/v1/alerts | Alert rules and what fired in the last 30 days. |
curl "https://api.lookoutstats.com/v1/boards/3f6c2a9e-8b1d-4c7a-9e2f-5d4b8a1c7e60/sites?range=7d" \ -H "Authorization: Bearer lk_live_your_key_here"
Responses come from the same cache as the dashboard, refreshed about every 15 minutes, so polling faster doesn’t give newer numbers. The OpenAPI description is at /v1/openapi.json.
Webhooks
- Add an endpoint in Settings → API & MCP: an HTTPS URL and the events you want.
- Verify the signature. Each request carries
X-Lookout-Signature, an HMAC-SHA256 of the body with the endpoint’s secret, in hex. The secret is shown in the endpoint’s settings, with a Copy button. - Send a test. A
pingevent arrives immediately so you can check the receiving side before anything real happens.
Events: alert.fired, site.spike, site.drop, digest.sent, report.sent, project.discovered, analytics.enabled. A failed delivery is retried three times with increasing delay; the last 30 days of deliveries, with status and timing, are listed under Recent deliveries, and a failed one can be sent again with one click. Pausing an endpoint keeps it and its history but stops sending.
{
"id": "6b1e0c4a-2f7d-4e93-a8c5-1d9f3b7e2a40",
"event": "site.drop",
"created_at": "2026-10-16T09:00:00.000Z",
"workspace_id": "org_2nT8kQ4xWvLm",
"data": {
"site": { "id": "prj_launch", "domain": "launch.northwind.io" },
"range": "7d",
"visitors": 1840,
"previous_visitors": 2674,
"change": -31.2,
"url": "https://lookoutstats.com/projects/prj_launch"
}
}If the URL is a Slack or Discord incoming webhook, Lookout formats the event as a readable message instead of sending the raw JSON.
What a key can’t do
Nothing that changes how your workspace is set up: no editing boards, members, alerts or settings, no reading other workspaces, and no access to your Vercel token. A key with Allow notes and exports can add chart notes and make export links, nothing more. Keys are tied to the workspace, not to the person who created them, so they keep working when a teammate leaves; revoke a key to stop it. When the workspace disconnects a Vercel team, that team’s sites drop out of every answer. Creating and revoking keys, changes to webhook endpoints and notes added through MCP are written to the workspace’s security log.
Who this is for
Agencies that already report in Sheets or Notion, developers who want deploy-and-traffic questions answered in their editor, and anyone who would rather be told about a drop than go looking for it. If you just want to see the boards, you don’t need any of this; the live demo shows the dashboard itself, and share links cover the “show a client” case without a key.