Sugra API
Gateway between LLM agents and world data through eight tools and a bundled endpoint catalog.
Sollte ich dies verwenden
Qualität und Sicherheit
Befunde (2)
- HIGH
- LOWin list_plans
Basierend auf einer automatisierten Analyse der Tool-Definitionen und der Einhaltung des Protokolls.
Kontextkosten
Dies ist die ungefähre Anzahl der Tokens, die jedes Mal verbraucht werden, wenn die Tools des Servers in den Kontext eines Modells geladen werden. Höhere Werte verringern die Aufmerksamkeit, die für andere Aufgaben verfügbar ist.
Installieren
Installation mit einem Klick
Fügen Sie dies Ihrer Datei `claude_desktop_config.json` hinzu:
{
"mcpServers": {
"api-mcp": {
"command": "uvx",
"args": [
"sugra-api-mcp"
]
}
}
}Ausführbare Pakete
0.12.0stdioRemote-Endpunkte
https://app.sugra.ai/mcpstreamable-httpWas es kann
Tool-Inventar
Tools (13)
🟢sugra_entity_screen(name, country, dob, nationality)
Screen a person or organization name against the Sugra sanctions corpus. Returns a SCREENING SIGNAL, not a compliance determination. Sugra is a technology provider, not a sanctions authority or consumer reporting agency. PEP and adverse-media coverage is supplementary and non-comprehensive - a `clear` result is not proof of absence, and a `hit` is a candidate match to review, not a finding. Output is COMPACT to protect the agent context budget: `{status, matches:[{name, score, list, type}], disclaimer}`. The verdict `status` is one of `clear`, `review`, or `hit`. The heavy raw fields (match rationale, source ids, publish dates) are dropped; use the Sugra API directly when the full screening envelope is needed. Args: name: The person or organization name to screen (required). country: Optional ISO 3166-1 alpha-2 country to narrow the match. dob: Optional date of birth (YYYY-MM-DD) for a person. nationality: Optional nationality to narrow the match.
Eingabe-Schema
{
"type": "object",
"properties": {
"name": {
"description": "Person or organization name to screen (required).",
"title": "Name",
"type": "string"
},
"country": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional ISO 3166-1 alpha-2 country to narrow the match.",
"title": "Country"
},
"dob": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional date of birth for a person, YYYY-MM-DD.",
"title": "Dob"
},
"nationality": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional nationality to narrow the match.",
"title": "Nationality"
}
},
"required": [
"name"
],
"title": "sugra_entity_screenArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "sugra_entity_screenDictOutput"
}🟢sugra_entity_lookup(anchor, value, include)
Resolve an entity by identifier and return its composed KYB envelope. `anchor` is `lei` (Legal Entity Identifier, resolved via the GLEIF registry) or `vat` (EU VAT number, validated via the EU VIES service). The result weaves identity, a sanctions screening signal, and - on request - ownership and adverse-media slices. The screening verdict is a SCREENING SIGNAL, not a compliance determination, and any PEP / adverse-media content is supplementary and non-comprehensive. The `disclaimer` field carries this and is always present. Output is COMPACT by default to protect the agent context budget: `{entity:{name, anchor, value, status, country}, screening:{status, top_matches:[...3], hit_count}, ids:{...}, disclaimer}`. Pass `include` to opt INTO fuller per-slice detail, e.g. `include=["ownership","adverse_media"]` adds those slices in full form. On a bad anchor or an API error this returns a clean `{error, detail}` dict rather than raising, so the agent can branch on `result.get("error")`. Args: anchor: Identifier type, one of `lei` or `vat`. value: The identifier value (the 20-char LEI code or the VAT number). include: Optional list of fuller slices to add, e.g. `["ownership", "adverse_media"]`. Omit for the compact default.
Eingabe-Schema
{
"type": "object",
"properties": {
"anchor": {
"description": "Identifier type: lei (GLEIF) or vat (EU VIES).",
"enum": [
"lei",
"vat"
],
"title": "Anchor",
"type": "string"
},
"value": {
"description": "The identifier value: 20-character LEI or the VAT number.",
"title": "Value",
"type": "string"
},
"include": {
"anyOf": [
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional fuller slices to add, e.g. ownership, adverse_media. Omit for the compact default. profile and screening are already in the compact core and are not extra slices.",
"title": "Include"
}
},
"required": [
"anchor",
"value"
],
"title": "sugra_entity_lookupArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "sugra_entity_lookupDictOutput"
}🟢search_endpoints(query, toolset, source, limit)
Search the bundled Sugra endpoint catalog by natural-language query. Use this to pick an operation_id. It does not fetch data. Typical loop: 1. search_endpoints(query) -> ranked hits with required_parameters 2. describe_endpoint(operation_id) -> params, request_body_schema, agent_hints 3. call_endpoint(operation_id, params=..., body=...) or fetch_data(query, params=...) Filter with toolset or source only after list_toolsets / list_sources; a misspelled filter is an error, not a silent empty result. Examples: - search_endpoints("US CPI inflation") - search_endpoints("AAPL price", toolset="markets") - search_endpoints("container ship AIS", toolset="network")
Eingabe-Schema
{
"type": "object",
"properties": {
"query": {
"description": "Natural-language search over the bundled catalog. Name the instrument, series, place, or task (examples: 'US CPI', 'AAPL quote', 'North Sea AIS'). Returns ranked operation_id hits with required_parameters. Then call describe_endpoint on a hit before call_endpoint.",
"title": "Query",
"type": "string"
},
"toolset": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional catalog group filter (markets, macro, news, network, ...). Call list_toolsets for the live names. An unknown value returns error unknown_toolset with known_toolsets rather than an empty hit list.",
"title": "Toolset"
},
"source": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional source-family filter as listed by list_sources (macro, markets, ...). An unknown value returns error unknown_source with known_sources.",
"title": "Source"
},
"limit": {
"default": 10,
"description": "Maximum ranked hits to return. Default 10. Does not call the Sugra API; this only bounds the catalog search list.",
"title": "Limit",
"type": "integer"
}
},
"required": [
"query"
],
"title": "search_endpointsArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "search_endpointsDictOutput"
}🟢describe_endpoint(operation_id)
Describe one Sugra API endpoint by operation_id. Includes agent_hints (duration_class fast/slow/heavy, max_concurrency, bulk billing) so you can budget timeouts and parallelism before calling. POST endpoints with a JSON body also carry request_body_schema (the resolved JSON schema) - construct the `body` argument from it instead of guessing key names. Call this after search_endpoints and before call_endpoint when you need the exact parameter names and examples.
Eingabe-Schema
{
"type": "object",
"properties": {
"operation_id": {
"description": "Catalog operation_id from search_endpoints (or from list_toolsets drill-down). Unknown ids return error unknown_operation_id.",
"title": "Operation Id",
"type": "string"
}
},
"required": [
"operation_id"
],
"title": "describe_endpointArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "describe_endpointDictOutput"
}🟢call_endpoint(operation_id, params, body, limit, fields, ...)
Call a Sugra API endpoint by operation_id from the bundled catalog. Plan calls with describe_endpoint's agent_hints: duration_class "fast" usually responds in under ~2s, "slow" usually 1-5s and occasionally 15s+ on a cold upstream, "heavy" can exceed the gateway timeout - keep parallel calls within max_concurrency and prefer small batches. Bulk endpoints bill 1 request credit per body item. Failures return structured errors {error, reason, status_code, elapsed_ms, retry_hint}; after "upstream_timeout" a single retry often succeeds because the aborted attempt warms upstream caches.
Eingabe-Schema
{
"type": "object",
"properties": {
"operation_id": {
"title": "Operation Id",
"type": "string"
},
"params": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"default": null,
"description": "Query and path parameters for this operation_id. Keys and types are operation-specific - call describe_endpoint(operation_id) first to get the exact parameter names, types, and examples. Omit if the operation takes none.",
"title": "Params"
},
"body": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"items": {
"additionalProperties": true,
"type": "object"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "JSON request body for a POST operation, matching the request_body_schema returned by describe_endpoint(operation_id): a JSON object for most operations, or a JSON array when that schema's top-level type is array. Omit for GET operations.",
"title": "Body"
},
"limit": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"description": "Bounds ONLY the records list: the data list, a bare top-level array, or the list inside an object data when exactly one of these keys holds a list: data, entries, events, history, items, observations, points, records, results, rows, series, timeseries (for example data.items). No such list, or several, means the limit does not apply. Keys beside the list such as total and count are not rewritten, and lists nested inside records are never truncated. meta.shaped reports limit_applied and records_path.",
"title": "Limit"
},
"fields": {
"anyOf": [
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional projection of keys to keep on each record of the records list: the data list, a bare top-level array, or the list inside an object data when exactly one of these keys holds a list: data, entries, events, history, items, observations, points, records, results, rows, series, timeseries (for example data.items). Keys beside that list such as total and count stay. If a field names a key of data itself, or of a payload without data, that object is projected instead; an object data without such a list is otherwise kept whole. Dotted paths (geo.city) walk nested objects. If no field matches, nothing is removed. meta.shaped reports fields_applied, fields_unmatched and records_path. Omit to keep every key.",
"title": "Fields"
},
"include_raw": {
"default": false,
"description": "If true, attach the original unshaped payload under raw when it fits the size cap; otherwise meta.raw_omitted explains why. Default false.",
"title": "Include Raw",
"type": "boolean"
}
},
"required": [
"operation_id"
],
"title": "call_endpointArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "call_endpointDictOutput"
}🟢list_toolsets
List catalog groups with endpoint counts and short descriptions. Use the group names as the toolset filter on search_endpoints. This does not call the Sugra API; it reads the bundled catalog.
Eingabe-Schema
{
"type": "object",
"properties": {},
"title": "list_toolsetsArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "list_toolsetsDictOutput"
}🟢fetch_data(query, params, body, limit, fields, ...)
One-step fetch: find the best Sugra endpoint for the query and call it. Combines search_endpoints + call_endpoint into a single round trip. Use this when you want data without manually picking an operation_id. The full search_endpoints + describe_endpoint + call_endpoint dance is still available when you need explicit control, but for most natural-language queries this tool is enough. Behavior: 1. Search the bundled catalog for the query. Top match wins. 2. If the matched endpoint has required parameters and they are all provided in `params`, call it and return the response. 3. If required parameters are missing, return the candidate endpoints and the missing-params list so the LLM can retry with the correct `params` dict on the next call. Examples: - `fetch_data("US CPI inflation", params={"series_id": "CPIAUCSL"})` → calls /api/v1/fred/series/CPIAUCSL, returns observations. - `fetch_data("Bitcoin price", params={"coin_id": "bitcoin"})` → calls /api/v1/crypto/bitcoin/price. - `fetch_data("Latest financial news")` → news_latest has no required params, returns latest news directly.
Eingabe-Schema
{
"type": "object",
"properties": {
"query": {
"description": "Natural-language request for data (examples: 'US CPI', 'Bitcoin price', 'latest news'). The tool picks the top catalog match and calls it. If required params are missing it returns needs_params instead of guessing.",
"title": "Query",
"type": "string"
},
"params": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"default": null,
"description": "Parameters for the auto-selected endpoint. If omitted and the best-match endpoint has required parameters, the tool returns that endpoint's required_parameters and examples so you can retry with them filled in.",
"title": "Params"
},
"body": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"items": {
"additionalProperties": true,
"type": "object"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "JSON body for an auto-selected POST operation; the tool returns the request_body_schema to fill when the match needs one. Pass a JSON object or a JSON array as that schema's top-level type dictates.",
"title": "Body"
},
"limit": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"description": "Bounds ONLY the records list: the data list, a bare top-level array, or the list inside an object data when exactly one of these keys holds a list: data, entries, events, history, items, observations, points, records, results, rows, series, timeseries (for example data.items). No such list, or several, means the limit does not apply. Keys beside the list such as total and count are not rewritten, and lists nested inside records are never truncated. meta.shaped reports limit_applied and records_path.",
"title": "Limit"
},
"fields": {
"anyOf": [
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "Optional projection of keys to keep on each record of the records list: the data list, a bare top-level array, or the list inside an object data when exactly one of these keys holds a list: data, entries, events, history, items, observations, points, records, results, rows, series, timeseries (for example data.items). Keys beside that list such as total and count stay. If a field names a key of data itself, or of a payload without data, that object is projected instead; an object data without such a list is otherwise kept whole. Dotted paths (geo.city) walk nested objects. If no field matches, nothing is removed. meta.shaped reports fields_applied, fields_unmatched and records_path. Omit to keep every key.",
"title": "Fields"
},
"include_raw": {
"default": false,
"description": "If true, attach the original unshaped payload under raw when it fits the size cap; otherwise meta.raw_omitted explains why. Default false.",
"title": "Include Raw",
"type": "boolean"
}
},
"required": [
"query"
],
"title": "fetch_dataArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "fetch_dataDictOutput"
}🟢list_sources
List source families in the bundled catalog with endpoint counts. Use the family names as the source filter on search_endpoints. This does not call the Sugra API.
Eingabe-Schema
{
"type": "object",
"properties": {},
"title": "list_sourcesArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "list_sourcesDictOutput"
}🟢list_plans
List the paid Sugra API plans with prices, limits and checkout links. Four plans: Dev and Pro, each monthly or annual, priced in US dollars. Every plan includes every endpoint; plans differ only in the daily request limit. Give the chosen plan's checkout_url to your human: they sign up or sign in and pay in Stripe Checkout. Purchases through these links do not auto-renew: annual covers one fixed year, and monthly is bought again after the current month ends. This tool makes no network call and needs no API key.
Eingabe-Schema
{
"type": "object",
"properties": {},
"title": "list_plansArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "list_plansDictOutput"
}🔴buy_plan(plan, cadence, email, accept_terms)
Buy a Sugra API plan and receive a new API key, paid by the agent. Payment uses the Payment HTTP authentication scheme with Stripe. The first call fails with JSON-RPC error -32042 (Payment Required) and the payment challenge in error.data.challenges. Pay it, then call again with the same arguments and the credential in params._meta["org.paymentauth/credential"]. The result carries api_key, and the receipt is in result._meta["org.paymentauth/receipt"]. A refused payment fails with -32043 and a fresh challenge. The purchase creates a new Sugra account for email; an email that already has one gets a checkout_url for its owner instead, and no payment is taken. accept_terms must be true. Purchases do not auto-renew. No API key needed.
Eingabe-Schema
{
"type": "object",
"properties": {
"plan": {
"description": "Plan to buy: dev or pro. list_plans shows their prices and limits.",
"enum": [
"dev",
"pro"
],
"title": "Plan",
"type": "string"
},
"cadence": {
"description": "monthly buys one month, annual one fixed year. Neither renews.",
"enum": [
"monthly",
"annual"
],
"title": "Cadence",
"type": "string"
},
"email": {
"description": "Email for the new Sugra account the key belongs to.",
"title": "Email",
"type": "string"
},
"accept_terms": {
"description": "Must be true: accepts the Terms of Service at https://sugra.systems/terms-of-service.",
"title": "Accept Terms",
"type": "boolean"
}
},
"required": [
"plan",
"cadence",
"email",
"accept_terms"
],
"title": "buy_planArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "buy_planDictOutput"
}🟢resolve_entity(query, type_hint)
Resolve free text to a canonical market or macro entity. Turns a ticker, company name, macro indicator, coin, or currency pair into the agent plane's ``{namespace, ids}`` entity for use with get_snapshot and get_timeseries. A cross-namespace collision (e.g. a ticker that is both an equity and a coin) returns status "ambiguous" with ranked candidates and NEVER silently picks one; pass type_hint (e.g. "equity", "etf", "coin") to narrow the universe. Crypto aliases resolve too (e.g. "bitcoin" -> the BTC coin entity). Status "low_confidence" means the best match cleared resolution but scored weakly - verify the returned entity before building on it, or re-query with a more specific name or type_hint. For compliance KYB lookups by LEI/VAT or sanctions screening use sugra_entity_lookup / sugra_entity_screen instead - this tool is for market-data entities. Args: query: Free-form text - ticker, company, indicator, coin, or pair. type_hint: Optional namespace hint narrowing resolution.
Eingabe-Schema
{
"type": "object",
"properties": {
"query": {
"title": "Query",
"type": "string"
},
"type_hint": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Type Hint"
}
},
"required": [
"query"
],
"title": "resolve_entityArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "resolve_entityDictOutput"
}🟢get_snapshot(recipe, entity)
Composed current view of an entity via a named recipe. Executes a fixed server-side recipe (company_snapshot, etf_snapshot, quote_snapshot, macro_indicator_snapshot, macro_calendar, earnings_snapshot, debt_snapshot) and returns one envelope with freshness, provenance, per-component coverage, and billing. Composed calls charge the recipe's fixed cost (1-2 units) from the daily quota. status "partial" means an optional component was unavailable - the present components are still trustworthy; honor the freshness block (stale=true means the data aged past its budget). Args: recipe: Recipe name from the fixed manifest. entity: Entity dict from resolve_entity ({"namespace": ..., "ids": ...}).
Eingabe-Schema
{
"type": "object",
"properties": {
"recipe": {
"title": "Recipe",
"type": "string"
},
"entity": {
"additionalProperties": true,
"description": "Entity dict from resolve_entity ({namespace, ids}). Extra keys are ignored.",
"properties": {
"namespace": {
"description": "Entity namespace from resolve_entity.",
"type": "string"
},
"ids": {
"additionalProperties": true,
"description": "Identifier map from resolve_entity.",
"type": "object"
}
},
"required": [
"namespace",
"ids"
],
"type": "object"
}
},
"required": [
"recipe",
"entity"
],
"title": "get_snapshotArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "get_snapshotDictOutput"
}🟢get_timeseries(metric, entity, granularity, max_points)
Bounded timeseries for an entity: price, macro_series, etf_flows or etf_monthly_flows. Returns points oldest-first with an explicit downsampling flag when the raw series exceeded max_points. Times are UTC. Costs 1 unit per call. The two ETF flow metrics answer different questions and are not interchangeable. ``etf_flows`` is an ESTIMATE at filing cadence: one point per SEC filing refresh, so ``t`` is a filing date and even a wide window yields a handful of points. ``etf_monthly_flows`` is the fund's own creations and redemptions from its NPORT-P filing, so ``t`` is a calendar month (``YYYY-MM``) and each point carries the three filed components - sales, reinvestment, redemption - beside the net. Two things to read before quoting etf_monthly_flows. NPORT-P is filed per SERIES, so for a fund with more than one share class the figures cover every class and the payload says so in ``multi_class_series``; where the class count is unknown it says ``class_scope`` instead of staying silent. And a fund that files no NPORT-P at all, such as a commodity trust, is not an error: the call returns status ``partial`` with an empty point list and a ``reason``. Args: metric: One of price / macro_series / etf_flows / etf_monthly_flows. entity: Entity dict from resolve_entity ({"namespace": ..., "ids": ...}). granularity: Requested point granularity (default "1d"). max_points: Hard cap on returned points (default 500).
Eingabe-Schema
{
"type": "object",
"properties": {
"metric": {
"enum": [
"price",
"macro_series",
"etf_flows",
"etf_monthly_flows"
],
"title": "Metric",
"type": "string"
},
"entity": {
"additionalProperties": true,
"description": "Entity dict from resolve_entity ({namespace, ids}). Extra keys are ignored.",
"properties": {
"namespace": {
"description": "Entity namespace from resolve_entity.",
"type": "string"
},
"ids": {
"additionalProperties": true,
"description": "Identifier map from resolve_entity.",
"type": "object"
}
},
"required": [
"namespace",
"ids"
],
"type": "object"
},
"granularity": {
"default": "1d",
"title": "Granularity",
"type": "string"
},
"max_points": {
"default": 500,
"title": "Max Points",
"type": "integer"
}
},
"required": [
"metric",
"entity"
],
"title": "get_timeseriesArguments"
}Ausgabe-Schema
{
"type": "object",
"additionalProperties": true,
"title": "get_timeseriesDictOutput"
}Community
Nachweis