Skip to main content

MCP stdio-to-Streamable-HTTP proxy with Databricks OAuth

Project description

uc-mcp-proxy

MCP stdio-to-Streamable-HTTP proxy with Databricks OAuth.

Lets any MCP client that speaks stdio (e.g. Claude Desktop, Claude Code) connect to any Databricks MCP server — Managed, External, or Apps — handling authentication automatically.

Installation

# Run directly (no install needed)
uvx uc-mcp-proxy --url <MCP_SERVER_URL>

# Or install globally
uv tool install uc-mcp-proxy

Requires Python 3.10+.

Databricks MCP Server Types

Server Type URL Pattern
Managed MCP (UC Functions, Vector Search, Genie, SQL) https://<workspace>/api/2.0/mcp/functions/{catalog}/{schema}
External MCP (GitHub, Google Drive, and others) https://<workspace>/api/2.0/mcp/external/{connection_name}
Apps (custom MCP servers) https://<workspace>.databricks.com/apps/<app>/mcp

Apps require OAuth. Use --auth-type databricks-cli when connecting to a Databricks App. Managed and External MCP servers also work with PAT and other auth types.

Usage

Claude Desktop / Claude Code (.mcp.json)

Add to your MCP client configuration:

{
  "mcpServers": {
    "unity-catalog": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "uc-mcp-proxy",
        "--url", "<MCP_SERVER_URL>"
      ]
    }
  }
}

CLI

uc-mcp-proxy --url <MCP_SERVER_URL> [--profile <DATABRICKS_PROFILE>] [--auth-type <AUTH_TYPE>]
Flag Description
--url (required) Remote MCP server URL
--profile Databricks CLI profile name (uses default if omitted)
--auth-type Databricks auth type, e.g. databricks-cli
--meta KEY=VALUE Meta parameter injected into tools/call _meta (repeatable)

Meta Parameters (Managed MCP)

Databricks Managed MCP servers accept configuration — for example, selecting a SQL warehouse — via the MCP _meta field in the JSON-RPC request body, not as HTTP headers. See the Databricks meta-param docs for the supported keys per server type.

Use --meta KEY=VALUE (repeatable) — the proxy merges these into params._meta on every outgoing tools/call request:

uvx uc-mcp-proxy \
  --url https://workspace.databricks.com/api/2.0/mcp/sql \
  --meta warehouse_id=abc123

Or in .mcp.json:

{
  "mcpServers": {
    "sql-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "uc-mcp-proxy",
        "--url", "https://workspace.databricks.com/api/2.0/mcp/sql",
        "--meta", "warehouse_id=abc123"
      ]
    }
  }
}

If the MCP client already sets a _meta key that the proxy is also configured to inject, the proxy value wins and a warning is written to stderr.

How It Works

  1. Starts an MCP stdio server (stdin/stdout)
  2. Connects to the remote MCP server via Streamable HTTP
  3. Injects a fresh Databricks OAuth token on every HTTP request
  4. Bridges messages bidirectionally between the two transports

Authentication

Authentication is handled by the Databricks SDK. The SDK auto-detects the method, or you can force one with --auth-type.

Auth type Managed / External MCP Apps MCP
databricks-cli — token from ~/.databrickscfg ✅ recommended
pat — personal access token ❌ not supported
oauth-m2m — service principal
OAuth U2M — browser-based login

Development

uv sync                        # install dependencies
uv run pytest -m unit -v       # run unit tests
uv run pytest -m integration -v # run integration tests
uv build                       # build package

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uc_mcp_proxy-0.2.0.tar.gz (87.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

uc_mcp_proxy-0.2.0-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file uc_mcp_proxy-0.2.0.tar.gz.

File metadata

  • Download URL: uc_mcp_proxy-0.2.0.tar.gz
  • Upload date:
  • Size: 87.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for uc_mcp_proxy-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6bbd4b512545a1da3309719a05cc40d8d57657374e4bc7d2e497bbee14e1e403
MD5 d6f8f378768b42b82751270a63fb0053
BLAKE2b-256 0d3d96dde78244f079b287656a7bdfeb5ab6c9f554be1f9f7ed2bb0f9952afcb

See more details on using hashes here.

Provenance

The following attestation bundles were made for uc_mcp_proxy-0.2.0.tar.gz:

Publisher: publish.yml on IceRhymers/uc-mcp-proxy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file uc_mcp_proxy-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: uc_mcp_proxy-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for uc_mcp_proxy-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7039b9505619128c57ab7694d294241ee6a806d4be59ff909ae140c5a7183fc2
MD5 4f262f904dfe869b2aeefac38c03b6aa
BLAKE2b-256 896b32c3dcb7e4ccfd19a9ab13dbbc8b3bba4d694b37bd4217d5ae5730e7085a

See more details on using hashes here.

Provenance

The following attestation bundles were made for uc_mcp_proxy-0.2.0-py3-none-any.whl:

Publisher: publish.yml on IceRhymers/uc-mcp-proxy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page