sugra-api-mcp
Published in Anthropic's Connectors Directory. Available in Claude on the web, desktop and mobile, Claude Code and Cowork.
Published in the official OpenAI Plugins Directory. Available for ChatGPT and Codex.
Give any AI agent access to 1,600+ data endpoints across markets, economics, companies, government, news, climate, maritime and entity screening - through one MCP server.
Works with ChatGPT, Claude, Gemini, xAI, Cursor, VS Code and any MCP client.
Official Model Context Protocol server for the Sugra API: one connector, a bundled endpoint catalog, and structured tool results with source attribution on every answer.
See it in action
An agent answering a real question end to end - resolving entities, pulling live snapshots and history, and citing the source and freshness on every number:
More examples:
Macro research - one prompt builds a full G7 inflation and policy-rate table, each cell dated and sourced, with the unavailable ones flagged rather than faked:
Cross-domain snapshot - Brent crude, marine weather and regional risk pulled together for a shipping desk, each with its source and timestamp:
What a session looks like
Hosted MCP transcript (the three composed tools shown here run on the hosted endpoint). Captured example - wording and figures vary by run and as new BLS data is published:```text
User: Where does US inflation stand, and how has it trended over the past year?
resolve_entity("US inflation")
-> macro indicator cpi_us (U.S. Bureau of Labor Statistics)
get_snapshot("cpi_us")
-> latest reading with freshness, provenance and quota cost
get_timeseries("cpi_us", metric="macro_series", range="1y")
-> 12 monthly points with an explicit downsampling flag
Agent: US CPI printed 2.9% year over year in the latest release, down from
3.5% twelve months earlier - a steady decline since spring.
Source: U.S. Bureau of Labor Statistics via the Sugra API.
Every tool result carries structured metadata - source attribution, freshness, and rate-limit cost - so agents can cite sources and budget requests instead of guessing.
## How it works```mermaid
flowchart LR
A["AI agent<br/>(ChatGPT, Claude, Gemini, xAI, IDEs)"] --> B["Sugra MCP<br/>gateway tools, plus agent tools when hosted"]
B --> C["Sugra API<br/>1,600+ endpoints, 36 data domains"]
C --> D["160+ primary sources<br/>markets, economics, government,<br/>news, climate, maritime"]
Behind the gateway sits the Sugra API: 160+ primary sources - sovereign statistics agencies, central banks, intergovernmental bodies and more - feeding 1,600+ endpoints across 36 data domains. The server ships a bundled catalog of the full endpoint surface, so discovery (search, describe, toolsets) runs locally without network calls; only actual data requests hit the API.
What agents build with it
The Sugra API skills live in Sugra-Systems/sugra-api-skills. The server serves five of them as MCP resources (sugra://skills/...) from a pinned commit of that repository: resources/read the URI after connect.
Agent skills
These skills teach the catalog loop. The Claude Code plugin also connects the hosted Sugra MCP server; the Codex and Grok plugins and the skill folders add no MCP tools, so connect the server separately there (hosted or local). The plugin package for each agent lives in Sugra-Systems/sugra-api-plugins.
Claude Code```
/plugin marketplace add Sugra-Systems/sugra-api-plugins
/plugin install sugra-api-skills@sugra-api-plugins
Skills appear as `/sugra-api-skills:`, for example `/sugra-api-skills:discover-and-call`. The plugin also adds the hosted server `https://mcp.sugra.ai/mcp`; sign in to it once from `/mcp`.
### Codex```bash
codex plugin marketplace add Sugra-Systems/sugra-api-plugins
codex plugin add sugra-api-skills@sugra-api-plugins
Grok```bash
grok plugin install Sugra-Systems/sugra-api-plugins#xai
### Cursor, Gemini CLI and other agents```bash
npx skills add https://mcp.sugra.ai
Or copy the skill folders of sugra-api-skills into the agent's skills directory.
ChatGPT
The skills install from OpenAI's Plugins Directory. The MCP server attaches as a hosted connector at https://mcp.sugra.ai/mcp (permanent alias https://app.sugra.ai/mcp).
Six workflow prompts ship with the server and turn these into one-click flows in clients that surface MCP prompts:
- Market and macro research - "Compare inflation and central bank policy rates across the G7." (
macro_briefing) - Equity snapshots with sources - "Where does NVIDIA stand today - price, profile, and market backdrop?" (
market_snapshot) - Sanctions and compliance screening - "Screen this supplier and resolve its LEI identity." (
sanctions_screening) - Sector comparison - "Energy versus technology: valuations and flows side by side." (
sector_compare) - Climate, maritime and trade intelligence - "Red Sea shipping this week: chokepoint transits, crude price, and weather on the route." (
earth_conditionsplus the transport and commodities catalog) - Source discovery - "What does the catalog offer for fixed income, and from which institutions?" (
source_overview)
Every answer carries source attribution and freshness metadata, so agents cite instead of guessing.
Hosted MCP (recommended)
No install. In Claude, ChatGPT and Codex, add the Sugra API MCP server from a directory:
- Claude (web, desktop, mobile, Claude Code and Cowork): Add to Claude opens the Sugra API MCP server in Anthropic's Connectors Directory; connect it and sign in with your Sugra account. In claude.ai the directory is under Customize > Connectors. Claude Code signed in with a claude.ai account picks the connector up automatically;
/mcplists it. - ChatGPT and Codex: Add to ChatGPT opens the Sugra API MCP server in the OpenAI Plugins Directory.
Any other MCP client, or a manual setup, points at the hosted Streamable HTTP endpoint:```
https://mcp.sugra.ai/mcp
- The gateway tools plus the composed agent tools `resolve_entity`, `get_snapshot` and `get_timeseries`
- OAuth sign-in through the Claude and ChatGPT connector flows, or `Authorization: Bearer sugra_xxx_...` with an API key
- As a custom connector in claude.ai: Customize -> Connectors -> Add custom connector
- In ChatGPT: Settings -> Connectors -> Add MCP server
Already added Sugra to Claude as a custom connector? That connection keeps working and shows under "Custom". Connecting the Sugra API MCP server from the directory as well gives you two connections, so remove the custom one first, then connect from the directory.
## Local package
Runs on your machine over stdio (or self-hosted HTTP) with an API key:```bash
pip install sugra-api-mcp
- Eight gateway tools
- stdio for desktop clients and IDEs, Streamable HTTP for self-hosting
- Authenticates with
SUGRA_API_KEY
Get a free API key at app.sugra.ai/register (Free tier: 50 req/day).
Quick start```bash
pip install sugra-api-mcp
export SUGRA_API_KEY=sugra_xxx_... # free key: app.sugra.ai/register
sugra-api-mcp call quotes_symbol_price --params '{"symbol":"AAPL"}'
The same call through an agent: connect the server to your client (next section) and ask "What is AAPL trading at? Use Sugra." The agent finds `quotes_symbol_price` in the catalog and calls it with the symbol.
## Connect your client
Supported clients:
- **Anthropic Claude**: Claude Desktop, Claude Code (CLI), claude.ai (web)
- **OpenAI GPT**: ChatGPT (via MCP connector)
- **Google Gemini**: Gemini CLI, Gemini Code Assist (VS Code + JetBrains)
- **xAI**: Remote MCP Tools in xAI SDK and Responses API
- **IDEs**: VS Code (native), Cursor, Zed, Cline, Continue.dev, Windsurf
- **Custom agents**: anything built on the Python or TypeScript MCP SDK
### Claude Desktop (stdio)
Add to `claude_desktop_config.json`:
- macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`
- Windows: `%APPDATA%\Claude\claude_desktop_config.json`
- Linux: Claude Desktop has no Linux build. On Linux, `pip install sugra-api-mcp` and use Claude Code (CLI), an IDE client, or the hosted HTTP endpoint below.```json
{
"mcpServers": {
"sugra": {
"command": "sugra-api-mcp",
"env": {
"SUGRA_API_KEY": "sugra_xxx_yourkey..."
}
}
}
}
Restart Claude Desktop. Sugra tools appear in the tools menu.
Claude Code (Anthropic CLI)
Signed in to Claude Code with a claude.ai account? Add to Claude connects the Sugra API MCP server from the Connectors Directory in claude.ai, and it appears in /mcp without any local install. To run the local package instead:```bash
claude mcp add sugra -- sugra-api-mcp
then set the env var that sugra-api-mcp reads
export SUGRA_API_KEY=sugra_xxx_...
Or edit `~/.claude/config.json` manually with the same shape as Claude Desktop above.
To install the skills as a plugin, which also connects the hosted server:```
/plugin marketplace add Sugra-Systems/sugra-api-plugins
/plugin install sugra-api-skills@sugra-api-plugins
Sign in to the plugin's server once from /mcp. If the Sugra API connector from claude.ai is connected too, Claude Code shows only the plugin's server. Running the local package as well gives you two Sugra servers: remove it with claude mcp remove sugra, or skip the plugin and copy the skill folders of sugra-api-skills into ~/.claude/skills/.
Usage with Gemini CLI
Gemini CLI reads MCP servers from ~/.gemini/settings.json (user scope) or
.gemini/settings.json in the project. For a local stdio install, add:```json
{
"mcpServers": {
"sugra": {
"command": "sugra-api-mcp",
"env": {
"SUGRA_API_KEY": "sugra_xxx_yourkey..."
}
}
}
}
If the console script is not on `PATH`, use `"command": "python"` with
`"args": ["-m", "sugra_api_mcp"]` instead. The equivalent Gemini CLI command
is:```bash
gemini mcp add --scope user -e SUGRA_API_KEY=sugra_xxx_yourkey... sugra sugra-api-mcp
Or connect to the hosted endpoint without installing the package:```bash
gemini mcp add --scope user --transport http \
--header "Authorization: Bearer sugra_xxx_yourkey..." \
sugra https://mcp.sugra.ai/mcp
Run `gemini mcp list` to check the connection, then enter `/mcp` in an
interactive session to inspect the available tools. A local stdio connection
shows the eight gateway tools in Tool reference; the hosted
endpoint also shows the three hosted-only agent tools.
If a local server does not connect from a new directory, review and trust that
workspace with `gemini trust` before retrying.
These examples were checked against the
Gemini CLI MCP documentation
and Gemini CLI v0.51.0.
### Cursor, Zed, Cline, Continue.dev, Windsurf
Each of these has an MCP settings file (typically `mcp.json` or equivalent) with the same stdio config shape as Claude Desktop.
### ChatGPT
Add to ChatGPT installs the Sugra API MCP server from the OpenAI Plugins Directory. Or add the hosted HTTP endpoint (below) as an MCP connector, since ChatGPT does not launch local stdio processes.
### HTTP (claude.ai, ChatGPT, remote agents)
In claude.ai, Add to Claude connects the Sugra API MCP server from Anthropic's Connectors Directory; in ChatGPT, Add to ChatGPT installs it from the OpenAI Plugins Directory. For a manual setup or any other Streamable HTTP MCP client, use the hosted endpoint:```
https://mcp.sugra.ai/mcp
Authenticate with OAuth in the connector flow or with Authorization: Bearer sugra_xxx_....
As a custom connector in claude.ai: Customize -> Connectors -> Add custom connector.
In ChatGPT: Settings -> Connectors -> Add MCP server.
Tool reference
The local package exposes eight gateway tools. The hosted endpoint adds three composed analysis tools on top (see Hosted MCP above). The package exposes exactly eight tools:
| Tool | Purpose |
|---|---|
fetch_data |
One-step: find best endpoint for a natural-language query and call it. Combines search + call in one round trip. |
search_endpoints |
Search the bundled endpoint catalog. Runtime search does not fetch /openapi.json. |
describe_endpoint |
Inspect an endpoint by operation_id, including path, method, parameters, required inputs, agent_hints, and request_body_schema for JSON-body POST operations. |
call_endpoint |
Call a Sugra API operation by operation_id. Arbitrary path calls are no longer supported. |
list_toolsets |
List catalog groups with endpoint counts and descriptions. |
list_sources |
Show bundled catalog source metadata. |
sugra_entity_screen |
Screen a name against sanctions and watchlists (Sugra Entity). |
sugra_entity_lookup |
Composed entity lookup by identifier - anchor is lei or vat, plus the identifier value; returns registry identity + screening (Sugra Entity). |
call_endpoint and fetch_data both support response shaping with limit, fields, and include_raw. Shaping works on enveloped ({"data": ...}) and envelope-less payloads alike; fields entries may use dotted paths into nested objects (geo.city), and meta.shaped reports what was actually applied (fields_applied / fields_unmatched, limit_applied, records_path, order, kept_end) rather than echoing the request. limit and fields work on the records list: the envelope data list, a bare top-level array, or the one list inside an object data when exactly one of data, entries, events, history, items, observations, points, records, results, rows, series, timeseries holds a list (for example data.items on the latest news, data.observations on a FRED series). When data has no such single list but every one of its values is an object holding exactly one list named observations, as with several named sub-series side by side, limit bounds each data..observations list on its own; fields there still names keys of data. Keys beside that list, such as total and count, stay as sent, and lists nested inside records are never truncated. A fields entry that names a key of data itself projects that object instead, and a projection that matches nothing leaves the payload whole. meta.shaped.limit_applied says whether the bound took effect, and meta.shaped.records_path names the list used (data, data., data.*.observations, or null when no records list was used). limit keeps the newest end of the records list when every record carries one date or period key (such as date, period or year) in one format and the list runs one way by it: the last N records of an oldest-first list, in their order, or the first N of a newest-first list. Otherwise it keeps the first N records. Whenever a limit bounds a records list, meta.shaped.order says asc, desc or unknown and meta.shaped.kept_end says newest or first, each as a map by sub-series name for sibling sub-series. A top-level JSON array (or scalar) is always wrapped as {"data": ...} so the MCP result stays an object; otherwise FastMCP output validation reports the successful call as an error and drops the rows.
fields takes at most 32 paths, each at most 256 characters and 16 dotted parts; past any of these the call answers projection_too_large before any request is made. With fields, one projection also visits at most 100,000 list items, runs for at most 5 seconds, and takes a response of at most 2,000,000 characters of JSON before projection. That bound sits far above the 18,000-character limit on the result, which applies after projection: a 16-day weather forecast is about 295,000 characters before fields=["daily"] cuts it to fit. None of these bounds applies without fields. Shaping runs on its own pool of two worker threads, never on the event loop: at most 8 jobs run or wait for a worker, 4 of them for one caller, and a call that finds no free slot within 2 seconds answers server_busy with scope shaping or caller_shaping.
describe_endpoint returns computed agent_hints per endpoint so agents can budget time and parallelism before calling:
duration_class-fast(under ~2s, snapshot-backed),slow(live upstream proxying, occasionally 15s+), orheavy(per-item upstream work, large batches can exceed the gateway timeout)max_concurrency- advisory ceiling for parallel calls from one sessionbulk_cost- on per-item bulk endpoints: 1 request credit per item in the request body (the API reports the total in theX-RateLimit-Costresponse header)
Hosted-only agent tools (mcp.sugra.ai/mcp)
The hosted MCP endpoint at https://mcp.sugra.ai/mcp serves the same eight tools PLUS three composed agent tools that are not available on stdio or self-hosted installs:
| Tool | Purpose |
|---|---|
resolve_entity |
Free text (ticker, company, indicator, coin, currency pair) to a canonical market or macro entity. Ambiguous matches return ranked candidates, never a silent pick. |
get_snapshot |
Entity plus a named recipe to one composed current view with freshness, provenance, coverage, and billing blocks. Composed calls charge a fixed recipe cost (1-2 requests) from the daily quota. |
get_timeseries |
Entity plus metric (price, macro_series, etf_flows, etf_monthly_flows) to a bounded series with an explicit downsampling flag. etf_flows estimates at filing cadence; etf_monthly_flows is the fund's own NPORT-P monthly creations and redemptions. |
These three tools wrap an internal composed plane that requires an infrastructure credential available only on the hosted deployment. The tool code ships inside the package, but it is registered only by the hosted HTTP entry point and only when that credential is present - pip install sugra-api-mcp (stdio and self-hosted HTTP) always exposes the classic eight-tool gateway. Hosted-only examples in any documentation are labeled as such. For compliance entity lookups (LEI / VAT, sanctions screening) use sugra_entity_lookup and sugra_entity_screen, which work on every transport.
ChatGPT tool set
A session whose MCP initialize names the client openai-mcp (ChatGPT), or that sends no client name and a User-Agent starting with it, lists 142 typed tools in place of search_endpoints, describe_endpoint, call_endpoint and fetch_data, beside the other tools above: one tool per operation, with a verb name such as get_stock_quotes or get_price_history, its own input schema and a compact result. Typed tools take no raw location inputs (coordinates, addresses, postal codes). A typed tool may take fewer inputs than its operation: get_latest_news, search_news and search_global_news_articles take one required topic or name and a count, while other clients still reach every input of those operations through call_endpoint. Of the 145 typed tools defined, those three are not listed to such a session (CHATGPT_UNLISTED_TYPED_TOOLS in sugra_api_mcp/server.py). Nothing such a session is listed names a tool it is not listed: list_toolsets and list_sources carry a description without the search_endpoints filter tip, and the prompts and the sugra://skills/ resources it reads come in a wording that names only the tools it is listed. Every other client lists the tools above unchanged; any client may still call any of these tools by name. The set is defined in sugra_api_mcp/catalog/data/typed_tools.json.
CLI
Server startup is unchanged:```bash
sugra-api-mcp
sugra-api-mcp --transport streamable-http --port 8001
Catalog and gateway helpers:```bash
sugra-api-mcp doctor
sugra-api-mcp list-toolsets
sugra-api-mcp search "NASDAQ futures"
sugra-api-mcp describe cot_financial
sugra-api-mcp call quotes_symbol_price --params '{"symbol":"AAPL"}'
Environment variables
User-facing configuration for local installs, MCP clients, Docker stdio, and
directory sandboxes (for example Glama Try in Browser). Set only this:
| Variable | Required | Default | Description |
|---|---|---|---|
SUGRA_API_KEY |
For API calls | - | Your Sugra API key (sugra_...). Get a free key at app.sugra.ai/register (Free tier: 50 req/day). Not needed to start the server: catalog tools (search_endpoints, describe_endpoint, list_toolsets, list_sources) work without it; API-calling tools return a structured missing_api_key error until it is set. In HTTP mode with a client Bearer token this is only a fallback. |
Optional overrides (leave unset unless you need them):
| Variable | Default | Description |
|---|---|---|
SUGRA_API_BASE |
https://sugra.ai |
Override the Sugra API base URL (self-hosted or beta API only). |
SUGRA_TIMEOUT |
30 |
Downstream HTTP timeout in seconds for calls from this server to the Sugra API. |
Operator-only settings for self-hosted Streamable HTTP (reverse proxy CORS/hosts,
OAuth authorization-server wiring, and shared secrets) are documented in
docs/self-hosting.md. Do not put operator secrets into
public directory sandboxes. SUGRA_MCP_TRUST_PROXY_HEADERS (off by default)
makes the server read X-Real-IP and X-Forwarded-Host; set it only behind a
reverse proxy that overwrites both on every request, and never where clients
can reach the process directly (details in the same guide).
SUGRA_MCP_LIMITS (off by default) turns on request limits counted in the
server's own memory; the same guide lists its settings.
HTTP transport with OAuth
When running with --transport streamable-http the server allows unauthenticated MCP discovery requests (initialize, notifications/initialized, tools/list, resources/list, prompts/list, and ping) so ChatGPT Apps and other mixed-auth clients can discover tool metadata. Tool calls still require Authorization: Bearer .... Two token formats are accepted:
- Raw API key (
sugra_...) - passed through as the downstreamx-api-key. Compatible with earlier local API-key setups. - OAuth JWT - signature verified against the issuer's JWKS. The audience must match
https://app.sugra.ai/mcp, the token must includesugra:read, and hosted access is validated against APP before resolving the user's primary API key. Successful hosted OAuth requests update MCP connection activity in APP.
Most users should use the hosted endpoint https://mcp.sugra.ai/mcp with an API
key as Bearer instead of self-hosting OAuth; standalone OAuth clients sign in at
the alias https://app.sugra.ai/mcp for now. If you run your own HTTP process, see
docs/self-hosting.md.
Timeouts and the error contract
SUGRA_TIMEOUT caps each downstream HTTP call from this server to the Sugra API (default 30 seconds). It is one link in a longer chain; when a tool call fails, elapsed_ms in the error payload tells you which link cut it:MCP client (agent harness) own tool timeout, often 60-180s, client-controlled
-> hosted proxy (app.sugra.ai) 86400s, effectively unlimited
-> this server (httpx) SUGRA_TIMEOUT, default 30s
-> Sugra API -> upstreams 15-60s per upstream call, server-side
Tool failures return structured JSON instead of raising, so agents can pick a retry strategy:
error value |
Meaning | Retry strategy |
|---|---|---|
upstream_timeout |
No response within SUGRA_TIMEOUT (elapsed_ms close to timeout_s x 1000) |
Retry once: the aborted attempt usually completes server-side and warms upstream caches. Then narrow the request (smaller batch, tighter filters). |
upstream_connect_error |
Could not reach the Sugra API (DNS failure, connection refused) | Retry after a short delay. |
upstream_transport_error |
Connection dropped mid-request | Retry once. |
invalid_request_url |
The request could not be built, most often because its parameters make the URL longer than 65,536 characters; nothing was sent | Send fewer or shorter parameter values, or split the request. |
unusable_api_key |
The API key holds a character this server cannot send in a request header (one outside ASCII, a line break or another control character, or a space or a tab at either end); nothing was sent | Do not retry: the key has to be replaced (see Troubleshooting). |
response_too_deep |
The API's response is nested too deeply to measure, so it is not returned | Retry once; report if persistent. |
free-text string + status_code |
The API answered with HTTP 4xx/5xx; retry_after included when the API sent a Retry-After header |
Honor retry_after for 429/503; fix the request for 4xx. |
tool_execution_failed |
Unexpected failure inside the gateway (exception_type included) |
Report if persistent. |
query_too_long |
A search_endpoints or fetch_data query has more than 64 terms or 1000 characters (max_terms and max_chars included). A term is a run of two or more ASCII letters or digits, and repeats count; nothing was searched |
Shorten the query to the instrument, series, place or task. |
projection_too_large |
A fields projection passed one of its bounds. limit_kind names it: fields (more than 32 paths), path_chars (a path over 256 characters), path_parts (a path over 16 dotted parts), rows (over 100,000 list items visited), shaping_ms (over 5 seconds) or raw_chars (a response over 2,000,000 characters before projection). limit, actual, field_index (from 0, for path_chars and path_parts) and operation_id are included, never the field text; the first three kinds are refused before any request is made |
Name fewer or shorter fields, add limit, narrow the request, or omit fields. |
server_busy |
A concurrency limit was reached. scope is tool_calls, search or shaping for a server-wide limit, caller_tool_calls, caller_search or caller_shaping for the limit on one caller. With shaping or caller_shaping the API request was already made and its response was dropped; with any other scope the call did no work |
Retry after a few seconds. |
All error payloads carry elapsed_ms. url is present on transport and HTTP errors (not on tool_execution_failed, which can fire before a URL exists). On the three transport errors and invalid_request_url, status_code is null (no HTTP status was received) - consumers comparing status_code numerically should guard for that. If a tool call instead fails with a bare client-side message and no structured JSON, the timeout fired in your agent harness above this server: raise the client's tool timeout, not SUGRA_TIMEOUT.
Examples
Ask Claude:
- "Search Sugra endpoints for NASDAQ futures."
- "Describe the
cot_financialoperation." - "Call
quotes_symbol_pricewith symbol AAPL and return only symbol and price." - "List available Sugra toolsets."
Troubleshooting
Looking for get_market_price, get_macro_indicator, or get_news? Those curated tool names appear in some older directory listings and never shipped in this package - use fetch_data for one-step natural-language calls or search_endpoints plus call_endpoint for explicit routing.
missing_api_key in tool responses
The server starts and lists its tools without a key, but API-calling tools (call_endpoint, fetch_data, the entity tools) return {"error": "missing_api_key"} until the server can find one. Depending on how you run it:
- As an MCP tool from your client (Claude, ChatGPT, Gemini, xAI, IDE, etc.): check the env block in your MCP config file. Value should be a full key like sugra_ao1_..., not empty and not wrapped in extra quotes.
- Shell / CI: export SUGRA_API_KEY=sugra_... before running sugra-api-mcp.
- HTTP mode: set via .env or systemd EnvironmentFile, not the shell.
sugra-api-mcp doctor reports whether the key is visible to the process.
unusable_api_key in tool responses
The key the server has for the call holds a character this server cannot send in a request header (a letter outside ASCII, an invisible character, a line break or another control character, or a space or a tab at either end), so API-calling tools send no request and return {"error": "unusable_api_key"}, and a retry fails the same way. Depending on where the key comes from:
- A key pasted into a config file or an environment variable can pick up an invisible character on the way. Copy it again from app.sugra.ai/developer/keys.
- The key itself holds such a character, as some older keys do: rotate it at app.sugra.ai/developer/keys and use the new one. Over a sign-in connection (claude.ai, ChatGPT) the server uses your account's key and reads it again within five minutes. If the page does not offer to rotate the key, email support@sugra.systems.
401 Unauthorized or 403 Forbidden in tool responses
Key accepted but rejected. Common causes:
- Key was regenerated in app.sugra.ai/developer/keys and your config still has the old one.
- Typo - key contains only lowercase letters and digits, no spaces, no trailing newlines.
- Free tier was deactivated. Sign in to verify status.
429 Too Many Requests
Hit your plan's daily limit. Response headers include X-RateLimit-Reset with the UTC timestamp when the counter resets (midnight UTC). Over MCP the tool result carries reason: daily_limit_reached, status_code: 429, retry_after, a retry_hint that tells the model not to call a data tool again before the reset (the X-RateLimit-Reset time, or 00:00 UTC when the API sent no reset time or a value that is not one) and to tell the user, and daily_limit and plan when the API named them. Plans: sugra.systems/api/pricing.
Before the limit is reached, a call_endpoint or fetch_data result shows what is left: meta.quota holds limit, remaining (requests left today) and resets_at, copied from the API's X-RateLimit-* response headers. A result carries no meta.quota when the API did not report a quota.
Invalid Host header (only if self-hosting HTTP mode)
FastMCP has DNS rebinding protection for public hostnames behind a reverse
…(正文过长,页面只展示前面部分,完整内容见仓库)
