# Databricks

Databricks reads external MCP servers from Unity Catalog connections. Add Cakewalk's gateway as a custom HTTP MCP connection, and the tools become available in AI Playground, Genie Code, and Mosaic AI agents.

## Requirements

* `CREATE CONNECTION` privilege on the Unity Catalog metastore. Users who need to consume the connection require `USE CONNECTION` privilege.

## Install Method

Custom form in Catalog > Connections. Cakewalk's gateway connects via OAuth Dynamic Client Registration (DCR), which Databricks supports natively.

## Step 1: Open Catalog Connections

1. Open Databricks and sign in.
2. Navigate to **Catalog**.
3. Open **Connections**.
4. Click **Create connection**.

## Step 2: Configure the Cakewalk Gateway

1. Set **Connection URL** to `https://mcp-gateway.getcakewalk.io/mcp`.
2. Tick the **Is mcp connection** checkbox.
3. For authentication, select **Dynamic Client Registration**. Databricks registers itself with Cakewalk's gateway automatically.

## Step 3: Authenticate

Databricks initiates the OAuth flow against Cakewalk's well-known endpoints, registers as a client via DCR, and walks you through the consent flow. Sign in with your Cakewalk account and approve the Connection. Databricks stores the credential on the Unity Catalog connection record.

## Step 4: Add the MCP Server to a Surface

The Unity Catalog connection makes Cakewalk discoverable. Pick the surface that consumes it.

### AI Playground

1. Open the **AI Playground**.
2. Click **Tools** > **+ Add tool**.
3. Select **MCP Servers** > **External MCP servers**.
4. Choose your Cakewalk connection.

### Genie Code

In a Genie Code session, add MCP servers from the same Unity Catalog connection list.

### Mosaic AI Agents

Reference the Cakewalk connection from agent code via the External MCP server interface.

## Verifying It Works

In the AI Playground, ask the agent to list its available tools. The tools surfaced through the Cakewalk gateway appear in the response. In Cakewalk, the Databricks card on **My Agents** flips to **Connected** after the first agent call.

## Other Authentication Modes

Databricks also supports manual OAuth U2M (with pre-registered Client ID and Secret), OAuth Machine-to-Machine, Bearer token, and OAuth User-to-Machine Per User. For Cakewalk's gateway, Dynamic Client Registration is the simplest path and avoids manual credential management.

## Troubleshooting

* **Is mcp connection checkbox is missing:** the option appears only in Connection types that support MCP. Confirm your Unity Catalog metastore is on a recent release.
* **DCR fails:** confirm `mcp-gateway.getcakewalk.io` is reachable from your Databricks workspace, then retry. The DCR call hits `/connect/register/AgentForceMcp` on Cakewalk's gateway.

## Learn more

* [Connect to an external MCP server](https://docs.databricks.com/aws/en/generative-ai/mcp/external-mcp) from Databricks.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://www.cakewalk.security/docs/ai-agent-access/connections-and-integrations/agent-platforms/databricks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
