
# MCP server

The full API is available as an MCP server over streamable HTTP:

```text
https://laso.finance/mcp
```

The tools are generated from the live OpenAPI spec at runtime, so the tool set never drifts from the deployed API.

## Connect

There's no key to paste. The first connection opens your browser so you can sign in and approve the agent (OAuth 2.1 with PKCE).

```bash
# Claude Code
claude mcp add --transport http opensolid https://laso.finance/mcp

# Hermes
hermes mcp add opensolid --url https://laso.finance/mcp --auth oauth
```

```json
{ "mcpServers": { "opensolid": { "url": "https://laso.finance/mcp" } } }
```

Clients without OAuth can send an API key as `Authorization: Bearer <key>`.

## What you get

| Tools | Notes |
| --- | --- |
| One tool per API route: `order_card`, `push_to_card`, `send_bank_payment`, `get_account_balance` … | Names are the snake_case of each route's `operationId` |
| `get_agent_wallet`, `create_agent_wallet`, `agent_wallet_transfer`, `pay_x402_endpoint` | The managed-wallet calls, including paying any external x402 endpoint |
| `search_docs` | Searches the live agent docs |

Paid tools settle from the managed wallet automatically, so you never build a payment header. Before the first paid call, check `get_agent_wallet` and fund it.

## Events

The server supports MCP events. Subscribe to `notification.created` to be told about deposits, card issuance, refunds and balance changes, instead of polling.

## Docs-only server

A second, credential-free server covers the documentation alone at `https://docs.laso.finance/mcp`. Use it to work out which call does a job before you hold a key.
