dbtrail
Claude Integration

Connect Claude to dbtrail

Set up Claude to query your MySQL change history

dbtrail provides a hosted endpoint that lets Claude and other AI assistants query your MySQL change history directly. Under the hood, dbtrail's streaming and query capabilities are powered by the open-source bintrail CLI — dbtrail adds multi-tenancy, managed infrastructure, and this AI integration layer on top. Connect from claude.ai, Claude Desktop, Claude Code, Cursor, or any compatible AI app — no local software to install.

Prerequisites

  1. A dbtrail account with at least one registered server
  2. An API key (generate one from Dashboard → Settings → API Keys)

Connection methods

You just need a URL and an API key.

  1. Go to Settings → Integrations → Add
  2. URL: https://api.dbtrail.com/mcp
  3. Add your API key as the auth header
  1. Go to Settings → Integrations → Add remote integration
  2. URL: https://api.dbtrail.com/mcp
  3. Configure the API key as the authorization header
claude mcp add --transport http bintrail \
  https://api.dbtrail.com/mcp \
  --header "Authorization: Bearer bt_live_YOUR_API_KEY"

Add to your tool configuration:

{
  "mcpServers": {
    "bintrail": {
      "url": "https://api.dbtrail.com/mcp",
      "headers": {
        "Authorization": "Bearer bt_live_YOUR_API_KEY"
      }
    }
  }
}

npm stdio bridge (fallback)

For older AI apps that only support stdio transport, the bintrail-mcp npm package acts as a local bridge:

npx bintrail-mcp --api-key bt_live_YOUR_API_KEY

Or add to your app's tool config:

{
  "mcpServers": {
    "bintrail": {
      "command": "npx",
      "args": ["bintrail-mcp", "--api-key", "bt_live_YOUR_API_KEY"]
    }
  }
}

Prefer the remote endpoint

The direct remote connection is recommended for all apps that support it. The npm bridge is only needed for apps that exclusively support stdio.

Why API keys

Some AI apps don't handle interactive login flows. API keys solve this by providing a static token that can be configured once. API keys are available on all plans (including Free).

Verifying the connection

After setup, try asking:

"What servers do I have in dbtrail?"

If the connection is working, you'll see a response listing your registered servers and their status.

Permissions

Connecting Claude requires the mcp:connect permission. The following roles have this permission:

RoleAccess
ownerYes
adminYes
operatorYes
analystYes
viewerNo

Five tools are available to Claude: list_servers, list_tables, query, recover, and status. See Tools Reference for full details.

On this page