MCP Server
TreasurySpring's MCP server lets AI agents (Claude, ChatGPT, Cursor, and other Model Context Protocol clients) access an authorised user's investment data. It is a thin layer over the same backend that powers the REST API, exposed via Streamable HTTP with OAuth 2.0.
Every tool below is read-only. The MCP server cannot place subscriptions, modify maturity actions, manage webhooks, or shortlist indications. For any action that mutates state, please use the REST API or the portal.
Endpoint
https://api.treasuryspring.com/api/v1/mcp
Connecting
- Claude.ai (web) and Claude Desktop — Settings → Connectors → Add custom connector. Paste the endpoint URL above, then complete the OAuth flow with your TreasurySpring account.
- Claude Code (CLI) —
/mcpthen "Add new MCP server", select "Remote", paste the endpoint URL, complete OAuth. - Cursor, VS Code, and other MCP clients — Add a remote MCP server entry pointing to the endpoint URL. Most clients trigger the OAuth flow automatically on first connect.
- GitHub Copilot Chat — supported via Copilot's MCP connector setup; follow the host IDE's instructions for adding a remote MCP server.
- MCP Inspector (for testing) — run
npx @modelcontextprotocol/inspectorand point it at the endpoint URL.
Picking a Claude mode
If you're using Claude as the agent, the right mode depends on the workflow:
- Claude chat (claude.ai) — best for ad-hoc questions: "what are my current GBP holdings maturing this quarter?" The MCP connector executes a few tool calls and Claude answers in natural language. Lowest setup, no environment to maintain.
- Claude Code (CLI) — well suited to repeatable scripted workflows: you can save prompts as skills that combine TreasurySpring tools with shell, file access, or git. Among the Claude modes, Claude Code is the one that can write files directly (for example, dumping a CSV of positions) without the usual "I can't write to your computer" limitation seen in chat-only modes.
- Claude co-work / scheduled tasks — best for recurring reports: run a daily prompt that calls TreasurySpring alongside another MCP server (for example, an accounting tool) and emails the result. Useful when you want to combine TreasurySpring data with non-TreasurySpring sources in one report.
For consistent output formatting across recurring runs, define a skill file (a saved prompt template) — Claude Code will use it on every invocation so the report shape stays stable.
Authentication
OAuth 2.0 authorization code flow with PKCE. The server advertises Dynamic Client Registration (RFC 7591), so MCP clients do not need a pre-configured client_id. Refresh tokens are issued for long-lived sessions; access tokens are scoped to the authenticated user's entities only.
Available tools
All tools are read-only. Most require an entity_code — call get_entities first to discover the codes accessible to your account.
Responses use a uniform envelope. List tools return { "items": [...], "pageInfo": {...} } — the pageInfo block (limit, offset, hasNextPage, hasPreviousPage, totalCount) is present only on paginated tools. Detail tools return the object directly.
get_entities — List Entities
Retrieve paginated entities (client organisations) the user has access to. Returns a summary only: code and name. Use get_entity with the entity code to retrieve the full profile (address, currency, status, type, rating, account manager, restrictions).
Optional: limit, offset
get_entity — Get Entity
Retrieve the full profile of a specific entity (client organisation) by code. Returns name, address, currency, status, type, rating, account manager, restrictions, and family group. Use get_entities first to discover available entity codes.
Required: entity_code
get_indications — List Indications
Retrieve paginated indications (available investment opportunities) for a specific entity. An indication represents a product the entity can currently subscribe to. Returns a summary per indication only: uid, type, currency, productCode, indicativeYield, sector, term. Use get_indication with a uid for the full set of fields.
Required: entity_code Optional: limit, offset
get_indication — Get Indication
Retrieve full details for a single indication by entity code and uid. Returns all fields including uid, type, currency, productCode, issueDate, subscriptionDates, optionDate, maturityDate, indicativeYield, maximum, cellCode, obligorExposureCode, obligorExposureName, enabled, term, restricted, calendars, sector, minimum, enforceMinimum, enforceMaximum, and extension-related fields (extensionDays, finalDays, minExtensions, nbPenaltyExtensions). Use get_indications first to browse available indications and obtain uids.
Required: entity_code, uid
get_subscriptions — List Subscriptions
Retrieve paginated subscriptions (investment orders) for a specific entity. Returns a summary per subscription: uid, amount, yield, status, currency, productCode, cellCode, obligorExposureCode, subscriptionDate, maturityDate, maturityAction, indicationUid, and holdingUid. Supports optional date filters: min/max subscription date and min/max maturity date (all YYYY-MM-DD). The holdingUid field links to the resulting active holding — pass it to get_holding to retrieve the live position and its full terms.
Optional: entity_code, min_subscription_date, max_subscription_date, min_maturity_date, max_maturity_date, limit, offset
get_subscription — Get Subscription
Retrieve full details for a single subscription by uid, including signer and releaser. Useful for tracking a subscription until its holdingUid is populated. Once holdingUid exists, follow it with get_holding and treat the holding as the live source of truth. Use get_subscriptions first to browse subscriptions and obtain uids.
Required: entity_code, uid
get_holdings — List Holdings
Retrieve paginated holdings for a specific entity. A holding is an active investment position. Returns a summary per holding: uid, type, currency, entityCode, productCode, cellCode, obligorExposureCode, status, cost, value, maturityValue, issueDate, maturityDate, yield. Supports optional date filters: min/max subscription date, min/max maturity date, and min modified date (all YYYY-MM-DD). Use get_holding with a specific uid for full detail (extension terms, next/final yields, maturity actions, price per share, etc.).
Required: entity_code Optional: min_subscription_date, max_subscription_date, min_maturity_date, max_maturity_date, min_modified_date, limit, offset
get_holding — Get Holding
Retrieve a single holding by uid. Returns the same comprehensive fields as get_holdings (value, yield, maturity dates, extension details, etc.). Use this for a targeted lookup when you already have a uid — for example, from a subscription's holdingUid field.
Required: entity_code, uid
get_holding_indications — Get Holding Indications
Retrieve the indications available against a specific holding — for example, the FTFs the holding can roll or switch into at maturity. Returns full indication details (the same fields as get_indication). Identify the holding by entity_code and uid.
Required: entity_code, uid
get_holding_extensions — Get Holding Extensions
Retrieve the extension history of an extendable holding, most recent first. Each extension records the yield, price per share, and new maturity date applied at that extension. Fixed holdings have no extensions. Paginated; identify the holding by entity_code and uid.
Required: entity_code, uid Optional: limit, offset
get_cells — List Fund Cells
Retrieve all fund cells the user has access to. A cell is the investment fund vehicle that holds assets. Holdings and subscriptions each reference a specific cell via their cellCode field. Returns a summary per cell (code, name). Use get_cell with a specific code for full detail (documents, allowed obligor exposures).
get_cell — Get Fund Cell
Retrieve a single fund cell by code. A cell is the investment fund vehicle that holds assets; holdings and subscriptions reference a cell via their cellCode field. Use get_cells first to browse available cells and obtain codes.
Required: code
get_obligor_exposure — Get Obligor Exposure
Retrieve exposure information for a specific obligor (issuer/counterparty) by code. An obligor is the institution (e.g. a bank) that issues the investment product. Returns risk limits, credit details, and sector information.
Required: code
Reference resources
Beyond tools, the server exposes a few read-only MCP resources (via resources/list / resources/read) — durable reference material an agent can read once rather than re-deriving from every response:
treasuryspring://guides/holding-lifecycle— how holdings, subscriptions, cut-off, and live terms relate.treasuryspring://reference/field-glossary— units and semantics for amounts, yields, dates, and identifiers (read before doing arithmetic on amounts or yields — e.g. indicationminimum/maximumare in millions while subscriptionamountis in absolute units).treasuryspring://reference/enums— allowed values for holding status, subscription status, maturity action, and product type.
Example prompts
- "Which entities do I have access to?"
- "List my current holdings for entity TEST0001 maturing before March 2027."
- "What investment indications are available for entity TEST0001 today?"
- "Has subscription
abcd1234been issued as a live holding yet?"
Lifecycle
Holdings returned by the MCP server follow the same lifecycle described in FTF Lifecycle. For real-time positions, yield, maturity, cut-off, extension, redemption, or other live terms, prefer get_holdings or get_holding over get_subscriptions — a resulting holding can differ from the subscription in yield, issue timing, and maturity date.
Data accuracy
Agents are statistical rather than deterministic. They can summarise, infer, or extrapolate from tool output in ways that look authoritative but aren't always exactly right. A few guardrails worth keeping in mind:
- For any number that will appear on a report, in a payment instruction, or in compliance documentation, it's worth independently verifying by re-fetching with
get_holding(singular) or the equivalent REST endpoint. The MCP server returns the same data the REST API returns; the variability is in how the agent narrates it. - Agent suggestions such as "you should subscribe to X" are best treated as a starting point rather than a recommendation — the MCP server doesn't perform any underwriting.
- Holdings are the authoritative source for live terms. Subscriptions reflect requested intent; the resulting holding may differ in yield, issue timing, and maturity date.
Privacy and data handling
See the TreasurySpring privacy policy. The MCP server exposes the same investment data already accessible via the REST API; it introduces no additional data categories or sharing arrangements.