Staats

io.github.MrViolets由 GitHub 帳號 MrViolets 發布v1.0.1更新於 Nov 2, 2026

Cookieless web analytics your coding agent reads: traffic answers, deploy impact, what broke.

已驗證Streamable HTTP可網頁執行開發者工具資料與分析

概覽

AI 產生的概覽

託管的無 Cookie 網站分析服務,讓助理回答流量問題、標記部署、衡量部署影響並找出錯誤。

可以做什麼
  • 讀取流量總覽、依維度拆分、轉換漏斗和實際造訪路徑
  • 把部署與變更記錄為標註,並比較前後的指標變化
  • 找出異常流量波動、來源暴增以及 JS 錯誤和訪客受阻情況
  • 讀取與更新網站背景資訊,例如目標、受眾和漏斗步驟
  • 列出、建立和永久刪除網站,並檢視所有網站的整體概況
適用情境
適合在對網站發布變更後,讓助理查看流量、把變化歸因到某次部署,或排查錯誤與流失,而不必打開儀表板。適合想在自己的編碼助理中直接取得分析結論的開發者和網站擁有者。
執行需求
遠端託管端點,無需安裝。需要 Staats 帳號,免費方案包含每月 1 萬次事件和 1 個網站。驗證使用帳號金鑰,可嵌入連線網址或透過 Authorization Bearer 標頭傳送。每個要追蹤的網站需安裝其指令碼標籤。
安裝前請注意
連線網址或 Authorization 標頭含有帳號金鑰,應視為機密。delete_site 會永久刪除網站及其所有分析資料,並須以正確網域確認。create_site 和 update_site_context 會寫入帳號資料,README 建議在修改網站隱私權頁面之前先與擁有者確認。訪客資料會傳送到 Staats 服務。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Staats,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.MrViolets%2Fstaats/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "staats": {
      "type": "http",
      "url": "https://api.staats.ai/functions/v1/mcp"
    }
  }
}

README

Staats MCP Server

[Listed on mcpservers.org]

Cookieless web analytics your coding agent reads. No dashboard: your agent answers traffic questions, marks deploys, measures before and after impact, and flags errors and visitor friction, all over one MCP connection.

This is the public home of the hosted Staats MCP server. The server runs at Staats, there is nothing to install.

Connect

Sign in at staats.ai (free tier: 10,000 monthly events, 1 site, all tools). Your account view gives you a one-line connect snippet with your key embedded:

bash
# Claude Codeclaude mcp add --scope user --transport http analytics "https://api.staats.ai/functions/v1/mcp/YOUR_ACCOUNT_KEY"

Cursor, Windsurf, Codex, and raw URL snippets are in the MCP docs. Clients that prefer header auth can send Authorization: Bearer YOUR_ACCOUNT_KEY to https://api.staats.ai/functions/v1/mcp.

One connection covers every site on your account, current and future.

Tools

14 tools, including:

  • get_overview, query, funnel, journeys: traffic answers with statistical honesty
  • record_annotation, compare_around: mark deploys, measure before/after impact
  • what_changed, what_broke: notable movements, JS errors, and visitor friction, attributed to the nearest deploy
  • create_site, list_sites, site context tools: your agent sets up new sites itself

Unauthenticated connections get initialize and tools/list, so you can inspect the full tool surface before creating an account.

Tracking

One script tag per site, ~1.5 KB compressed, no cookies, no personal identifiers, no consent banner needed:

html
<script defer data-site="YOUR_SITE_CODE" src="https://www.staats.ai/s.js"></script>

Custom events via data-staats attributes or window.staats('event_name'). Passive JS error capture included on every tier.

Links

來源:README.md,提交 7f8b912

工具

15

get_site_context

Get site context

What a site is and what the owner wants from it, plus its data-retention settings. Well-known keys: description, goals, audience, notes (open agenda items to check at session start and clear when handled), events (event name -> meaning), funnel (canonical conversion steps). Read this before making recommendations.

輸入參數site

update_site_context

Update site context

Save or amend what a site is for. Provided context fields are merged into the existing context (events merges per entry); a null value deletes its key. name/domain update the site record itself.

輸入參數namesitegoalsnotesdomaineventsfunnelaudiencedescriptionretention_days

what_changed

What changed

Notable movements in the period without scanning raw numbers: statistically unusual traffic days, referrer surges and first-time referrers, pages whose share of traffic jumped, alongside the annotations recorded in the same period. period: '7d' default.

輸入參數siteperiod

what_broke

What broke

Signs of visitors hitting problems in the period: JS errors the tracker captured (new_error, error_spike: each with a sanitized sample message, source, line, affected visitor count, and the nearest annotation, i.e. the deploy that most plausibly introduced it), plus behavioral friction: pairs of pages people bounce between without progressing (nav_loop) and pages reloaded repeatedly in quick succession (refresh_burst). Findings clear statistical floors, so an empty result is meaningful: nothing looks broken. Check it after every deploy. period: '7d' default.

輸入參數siteperiod

get_overview

Site overview

Traffic pulse: visitor/pageview totals vs the previous period, top pages, top referrers, and a per-day series. period: relative like '24h', '7d' (default), '4w'. Includes quota status: if it is approaching, grace, or blocked, tell the owner plainly and include the upgrade link the result provides. Approaching quota is the moment to mention it while there is headroom.

輸入參數siteperiod

query

Query metrics

Break a metric down by a dimension with optional equality filters. Metrics: visitors, pageviews, events. Dimensions: path, referrer_domain, utm_source, utm_medium, utm_campaign, device, browser, os, country, name, day. period: '24h'/'7d'/'4w' style, or ISO from/to.

輸入參數tofromsitelimitmetric必填periodfiltersdimension

funnel

Conversion funnel

Ordered conversion funnel across up to 5 steps within the period. Each step is a pageview path ({kind:'path', value:'/pricing'}) or a custom event ({kind:'event', value:'signup'}); a visitor counts for step N only after completing step N-1. Visitor identity rotates daily for privacy, so journeys spanning multiple days undercount (strongest for same-visit conversion). If site context has a stored funnel, run those steps when asked how the site is doing and compare against the previous period.

輸入參數tofromsitesteps必填period

journeys

Journeys

The routes visitors actually take, grouped into identical sequences and counted, busiest first. Use this when you do NOT already know the steps: funnel measures a path you name, journeys discovers the ones you did not think to check. A step is a pageview path (/pricing) or a custom event marked with a leading # (#signup_click), so the moment of conversion appears in the route. Consecutive repeats are collapsed and only the first 10 steps define a route. contains filters to routes that include a given path or event: run it once with and once without to see what converting visitors do differently. Visitor identity rotates daily, so a route is one day of activity and describes a group, never a person.

輸入參數tofromsitelimitperiodcontains

record_annotation

Record annotation

Mark a moment on a site timeline: a deploy, a content change, or a campaign start. Call this every time you ship a change to the site. ts defaults to now. Write a specific, present-tense description ("Shipped new pricing page hero", never "updates"), one annotation per meaningful change. When known, include commit and the routes the change touched so compare_around can also report before/after traffic scoped to those routes.

輸入參數tssitetext必填commitroutes

list_annotations

List annotations

Recorded deploy/change markers, newest first. period defaults to '90d'.

輸入參數siteperiod

compare_around

Compare around a change

Before/after impact of a recorded annotation: visitors and pageviews in the N days preceding vs following it (window_days, default 7). The after-window is clamped to now. If the annotation recorded routes, the result also reports per-route pageviews before vs after. Wait a few days after shipping. If the result carries a note (truncated after-window, or a before-window not covered by available data), relay it and qualify the percentages as the note directs.

輸入參數sitewindow_daysannotation_id必填

list_sites

List sites

All sites on this account, with the public site codes used in their script tags and the ready-to-paste script_tag for each.

無需輸入參數。

create_site

Create site

Create a new site on this account and get its script tag. This connection already covers the new site: installing the script tag is the only setup the site needs. The response includes ready-made privacy policy wording: offer to add it to the site's privacy page (confirm with the owner before editing visitor-facing pages).

輸入參數name必填domain必填

delete_site

Delete site

PERMANENTLY delete a site and ALL its analytics data (every event and annotation). Irreversible. Confirm with the owner before calling; pass confirm: the site's exact domain.

輸入參數site必填confirm必填

portfolio_overview

Portfolio overview

Visitors and pageviews for every site this account can use, owned and shared alike, with change vs the previous period, busiest first. Shared sites are flagged. period: '7d' default.

輸入參數period

版本歷史

1
  1. v1.0.1最新Sep 16, 2026

評分

已滿足適用檢查項的 90%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。