Setup · Step by step

Connect Leeway MCP to your client

The easiest way is ChatGPT, Claude, Gemini or Perplexity: add Leeway, sign in, and start asking questions. Other connection options are available below.

Recommended route

ChatGPT, Claude, Gemini & Perplexity (OAuth)

ChatGPT, Claude, Gemini and Perplexity connect to your Leeway account via OAuth. You only add the server URL; sign-in and consent happen in the browser. No API token to copy; internally your existing token and quota are used.

Which client do you want to connect?

Choose the assistant in which the Leeway tools should appear. The next steps depend on that client and on its plan.

For other clients: use an API token

Cursor, VS Code, Claude Desktop with the local bridge, OpenAPI clients and other clients need an API token. Create a free account and copy the token from your account area.

Then follow the instructions below.

Further clients and developer setups

Custom GPTs, Cursor, Claude Desktop, VS Code and every other MCP client connect with an API token. Open the section for your client to see the full instructions including the configuration.

Custom GPTs & assistants (OpenAPI / REST)OpenAPI / REST

Assistants that don't support MCP can be connected using our OpenAPI specification. You provide the JSON schema and authenticate via a query parameter.

Find your API token in the account area. Copy it and replace YOUR_TOKEN below.

REST base URLhttps://api.leeway.tech
Authentication (query parameter)?apitoken=YOUR_TOKEN

Each schema below covers one product family. The full schema is too large for some importers, so add the smaller ones as separate skills or actions instead; together they still cover every endpoint.

Full schema (all endpoints)https://api.leeway.tech/openapi.json
Context APIhttps://api.leeway.tech/openapi-context-api.json
Data API (all)https://api.leeway.tech/openapi-data-api.json
Data API – Price Datahttps://api.leeway.tech/openapi-data-api-price-data.json
Data API – Fundamental Datahttps://api.leeway.tech/openapi-data-api-fundamental-data.json
Data API – General, Macro, Bonds & Newshttps://api.leeway.tech/openapi-data-api-rest.json
Analytics APIhttps://api.leeway.tech/openapi-analytics-api.json
Forecast APIhttps://api.leeway.tech/openapi-forecast-api.json
  1. Pick a schema URL below (use a smaller one if your tool rejects the full schema), open it in your browser, select all, and copy the JSON text.
  2. Create a new action or skill in your AI assistant and paste the copied JSON text into the 'Schema' field.
  3. Set the authentication type to 'API Key' (passed as a Query parameter). The parameter name is 'apitoken' and the value is your Leeway token.
  4. Before you use the client, top up your wallet or book an API package for market data.

  5. Save the configuration and repeat for any additional schemas you need. The endpoints will now be available as actions.
Cursor (Remote MCP)Remote MCP (HTTP)

Cursor connects remotely over Streamable HTTP. The fastest path is the one-click install; alternatively add the server to mcp.json manually.

Find your API token in the account area. Copy it and replace YOUR_TOKEN below.

Add to Cursor
  1. Click "Add to Cursor" or copy the config below.
  2. Open ~/.cursor/mcp.json and add the block under mcpServers.
  3. Replace YOUR_TOKEN with your Leeway API token.
  4. Before you use the client, top up your wallet or book an API package for market data.

  5. In Cursor settings under MCP, refresh the server, and the Leeway tools show up in chat.

Config file: ~/.cursor/mcp.json

{
  "mcpServers": {
    "leeway-api": {
      "url": "https://mcp.leeway.tech/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_TOKEN"
      }
    }
  }
}
Claude Desktop (stdio)Local bridge (stdio)

Claude Desktop connects through a local stdio bridge (mcp-remote) and an API token. This setup is separate from the OAuth connectors on the Claude website. You do not need to install or host a Leeway server for it.

Find your API token in the account area. Copy it and replace YOUR_TOKEN below.

  1. Make sure Node.js is installed (needed for npx; nothing else to install).
  2. In Claude Desktop, open Settings → Developer → Edit Config.
  3. Paste the block below and replace YOUR_TOKEN with your Leeway API token.
  4. Before you use the client, top up your wallet or book an API package for market data.

  5. Restart Claude Desktop, and the tools are ready in your conversation.

Config file: claude_desktop_config.json

{
  "mcpServers": {
    "leeway": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://mcp.leeway.tech/mcp",
        "--header",
        "Authorization:Bearer YOUR_TOKEN"
      ]
    }
  }
}
VS Code (Remote MCP)Remote MCP (HTTP)

VS Code (with an MCP-capable extension) connects remotely over Streamable HTTP, the same config as Cursor.

Find your API token in the account area. Copy it and replace YOUR_TOKEN below.

  1. Install an MCP-capable extension and open its MCP configuration.
  2. Add the server block below and replace YOUR_TOKEN.
  3. Before you use the client, top up your wallet or book an API package for market data.

  4. Reload the extension, and the tools become available.
{
  "mcpServers": {
    "leeway-api": {
      "url": "https://mcp.leeway.tech/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_TOKEN"
      }
    }
  }
}
Other MCP clients (Remote MCP)Other clients

Any MCP-compatible client connects with the same two pieces: the endpoint and the Authorization header. The endpoint is meant for MCP clients, not for opening in a browser (there you only get an auth message).

Find your API token in the account area. Copy it and replace YOUR_TOKEN below.

Endpointhttps://mcp.leeway.tech/mcp
Auth headerAuthorization: Bearer YOUR_TOKEN

Before you use the client, top up your wallet or book an API package for market data.

Note: opening the MCP endpoint directly in a browser returns an auth error, which is expected. It's only used by the MCP client with your token.

Available tools

After you connect, your client sees the catalogue of 24 tools. You select prices, company figures, and research with view or topic. Logo images stay on the HTTP API.

Specification of available Model Context Protocol tools.
Tool identifierCategoryParametersReturn payload & capability
general_isinGeneralisin Resolves an ISIN or a name to listings in SYMBOL.EXCHANGE form.
general_mainstockGeneralisin Returns the main listing of a company that trades on more than one venue.
general_directoryGeneralview, [exchange, type] view=exchanges lists the exchanges. view=symbols lists the securities on one exchange.
general_screenerGeneralfilters | signals | preset, [sort, limit, offset] Filters stocks by figures, signals, or a preset. At least one of the three is required.
general_tradingperiodGeneralsymbolExchange Returns the first and last date this stock traded on its exchange.
general_accountGeneralview view=credits is the AI wallet. view=requests_left is the remaining daily request budget.
pricesMarket Dataview, symbolExchange, [from, to, interval, multi] view=eod is daily prices. view=live is the latest quote. view=intraday requires interval 1m, 5m, or 1h.
prices_relative_moveMarket DatasymbolExchange Shows whether today’s move in this stock sits outside its usual trading range.
market_capMarket Dataview, [symbolExchange, type, valuation, from, to] view=history is one company’s valuation. view=aggregation is a multiple across companies; type is pe, pb, ps, pc, or liab.
benchmarkMarket Datasymbol, benchmark Returns the performance of one stock against the benchmark indexes you name.
market_lastdayMarket Dataexchange, [date, symbols] Returns one OHLCV bar per listed instrument on an exchange for a trading day.
fundamentalsFundamentalsview, symbolExchange, [fields, from, lang, fmt] view=statements is the statements and profile. view=keyfigures is calculated series. view=forecast is analyst estimates.
ratingsRatingssymbolExchange Leeway scores for Market-Fit, Business, Cycle, and Leeway, plus the Market-Fit factors.
dividendsMarket Dataview, symbolExchange, [from, to] view=latest is the dividend events. view=history is the daily dividend yield. Zero means no dividend is active that day.
splitsMarket DatasymbolExchange Returns stock splits with ratio and effective date.
eventsEvents & Macroview, [from, to, symbols] view=ipos, view=earnings, or view=splits is the calendar. view=trends requires symbols as SYMBOL.EXCHANGE.
macroEvents & Macroview, [country, indicator] view=indicators and view=countries are the directories. view=series is one country in Alpha-3.
sentimentEvents & Macrofamily, [series, from, to] Market sentiment. Omit series for the catalog, pass series for one series. naaim, fear_index, and smart_money are single series.
governmentEvents & Macro[series, from, to] Returns U.S. Treasury and Bureau of Labor Statistics series. Omit series for the catalog.
bondEvents & Macroisin Returns the bond figures for one ISIN.
newsEvents & Macro[s, from, to] Returns news for companies, stocks, and currencies. s is SYMBOL.EXCHANGE when you want one instrument.
ai_companyAI Contexttopic, symbolexchange, [lang, maxAgeDays, sources] Research on one stock. topic is whatsnew, timeline, competitors, risks, price_drivers, industry, or sector. Billed to the wallet.
ai_assetAI Contexttopic, symbolexchange, [maxAgeDays, sources] Research on a commodity or currency. topic is whatsnew, timeline, price_drivers, or events. Billed to the wallet.
ai_marketAI Contextview, [length, lang, cadence, topic, sources] view=weekly, daily, or cio_view is a stored briefing. view=timeline is the weekly timeline. view=topic requires cadence and topic.

Troubleshooting

No tools appear.

Check that the server is enabled and refreshed in the client. After editing the config, a restart or refresh is usually required.

401 / Unauthorized.

YOUR_TOKEN was not replaced, or the token is invalid. Get a fresh token in the account area.

Rate limit reached.

The free tier includes 50 request units per day. For production use, the Data API plan offers 100,000 per day.

Related topics

Explore how structured research briefs and shared caching complement the market data tools of the MCP server.

© Leeway
PWP Leeway UG (haftungsbeschränkt)
Leeway Icon