Overview

Single Origin MCP Server

New — The Single Origin MCP server is now available. Connect Claude Code, Cursor, or any MCP client.

The Single Origin MCP server exposes our query optimization data — query history, execution profiles, table metadata, similar-query clusters, and recommendations — as tools that any Model Context Protocol client can call. Drop it into Claude Code, Cursor, Claude Desktop, or your own agent, and your LLM can investigate slow queries and propose optimizations with grounded evidence instead of guesses.

Quickstart

1. Create a Personal Access Token. In the Single Origin web app, go to Account → Access Tokens, click Create Token, give it a name (e.g. Claude Code), and copy the Token ID and Token Secret from the dialog. The secret is shown only once.

2. Add the server to your MCP client config (Claude Code's .mcp.json, Cursor's MCP settings, or any other MCP-aware client). The Bearer value is <token_id>:<token_secret> — paste both values from the dialog, joined by a colon.

{
  "mcpServers": {
    "singleorigin": {
      "type": "http",
      "url": "https://mcp.singleorigin.tech/mcp",
      "headers": {
        "Authorization": "Bearer <token_id>:<token_secret>"
      }
    }
  }
}

3. Restart your client and run /mcp (Claude Code) or your client's equivalent to confirm the singleorigin server is connected.

What you can do

The server exposes 31 tools plus a set of built-in prompts, grouped by use case:

SectionToolsWhen to use
Recommendations4Surface and act on optimization opportunities Single Origin has already identified.
Query Inspection7Dig into a specific slow or expensive query — SQL, profile, fragments, warehouse/concurrency, and the tables it reads and writes.
Similar Query Clusters4Find groups of structurally similar queries, or search for queries similar to a new one; fix one shape to fix dozens.
Tables & References8Look up schema, partitions, and view definitions, resolve ambiguous table names, list the queries reading or producing a table, trace upstream/downstream lineage, and find structurally similar tables.
Table & Column Usage3See how columns are used over time, scan storage/usage metrics, and measure scan/pruning efficiency.
SQL Review Rules3Steer the SQL-review agent with custom, always-on rules.
User Management2List and create workspace users — present only when the gRPC backend is configured.
Built-in PromptsPre-written prompts that walk an agent through the most common workflows.

Exact availability depends on your deployment: the user-management tools and update_recommendation need the gRPC backend, and search_similar_queries needs embedding search enabled — so a given deployment may expose fewer than 31. Each tool's page notes its requirement.

Authentication

The hosted server validates Bearer tokens via Personal Access Tokens (format <token_id>:<token_secret>), scoped to your user. All tool calls run with your identity — you only see data your workspace already grants you. Tokens can be revoked at any time from Account → Access Tokens.

Troubleshooting

  • /mcp returns a redirect the client can't follow. Some MCP clients (older FastMCP, langchain4j) fail on trailing slashes. Use https://mcp.singleorigin.tech/mcp exactly as documented — no trailing slash.
  • 401 Unauthorized. Confirm you copied both the Token ID and the Token Secret from the dialog, joined by a colon: <token_id>:<token_secret>. The most common mistake is using only the Token Secret. Also check that the token hasn't expired and the Authorization: Bearer ... header is being sent.
  • /mcp connects but no tools appear. Restart your client — tool discovery only runs on (re)connect.

Have a use case we should support? Drop us a note at [email protected].


Did this page help you?