Codex can query Databricks through Genie One, Databricks' own MCP endpoint. It can also go through Contextflo, which connects to a SQL warehouse once and adds shared context for your team. Both configs are a few lines of TOML.
Option 1: Genie One MCP in Codex
Databricks exposes Genie as an MCP server at:
https://<workspace>/ai-gateway/mcp-services/system.ai.genie_one_mcp
Auth is OAuth. The older beta endpoint is deprecated on October 31, 2026, so use this one.
In ~/.codex/config.toml:
[mcp_servers.databricks]
url = "https://<workspace>/ai-gateway/mcp-services/system.ai.genie_one_mcp"
Genie works against Genie spaces. A space holds up to 50 tables. Databricks recommends five or fewer for accuracy, so plan to split broad data across spaces.
Option 2: Contextflo
Contextflo connects to a SQL warehouse and queries the tables you expose.
In Databricks:
- Find your SQL warehouse's HTTP path: SQL Warehouses, your warehouse, Connection details.
- Create a token for a service principal, or use a personal access token, with read access.
- Grant Unity Catalog
USE CATALOG,USE SCHEMAandSELECTon what you want to expose.
In Contextflo: go to Data Sources, then Add data source, and choose Databricks. Enter the host (your workspace URL), the HTTP path and the token. Pick tables and invite your team.
In Codex:
[mcp_servers.contextflo]
url = "https://mcp.contextflo.com/mcp"
codex mcp login contextflo
codex mcp list confirms the connection. Contextflo runs SELECT only.
Access in Contextflo is at table level. Unity Catalog adds row filters and column masks if you need them.
Which one to use
Just you, asking about a few curated tables: Genie One in Option 1.
Your team asks too: Contextflo. It generates table and column descriptions, your team saves shared definitions, each person gets their own table access, and you get an audit trail of prompts and the SQL that ran.
On Claude? See Claude with Databricks.
You do the modeling, we do the rest. Connect Databricks free.
FAQ
How many tables should a Genie space have for Codex? Genie spaces hold up to 50 tables. Databricks recommends five or fewer for accuracy.
Is the old Databricks Genie MCP beta endpoint still supported? The older beta endpoint is deprecated on October 31, 2026. Use the Genie One MCP endpoint under /ai-gateway/mcp-services/ instead.
What Unity Catalog grants does Contextflo need? USE CATALOG, USE SCHEMA and SELECT on what you want to expose. Unity Catalog row filters and column masks add finer control on top of Contextflo's table-level access.
Where do I find the HTTP path for a Databricks SQL warehouse? In Databricks, open SQL Warehouses, pick your warehouse, then Connection details.
See it on your own data.
Connect your warehouse and your team can ask Claude about it the same day, without waiting on a data team. Want a walkthrough first? Grab 20 minutes.
Book a 20-minute callSee how teams use Contextflo
Related posts
Keep reading

Conversational analytics: 5 ways to set it up, compared
7 min read

How to connect Claude to BigQuery? What works and what doesn't in 2026
8 min read

How to connect Claude to Postgres without giving it write access
9 min read

How to build a BI dashboard with Claude that your team can actually trust
8 min read

How to give Claude read-only access to your database (it isn't always the default)
7 min read

You connected your warehouse to Claude, now what?
5 min read

ClickHouse MCP: how to connect ClickHouse to Claude, Cursor or Codex
6 min read

Query BigQuery from the Codex CLI with MCP
5 min read

Run ClickHouse queries from Codex with MCP
6 min read


