Skip to content

Ask AI

Ask anything about Destesi — setup, products, APIs.

Powered by Claude. Answers may be wrong — always verify against the docs.

Connect your agent (MCP)

The Destesi MCP server lets an AI agent operate your Destesi data directly. It turns Destesi products into tools that any Model Context Protocol client can call — branch a database, open a preview environment, run a Connect action against GitHub or Slack, and (when you self-host the server) reach Drive, Deploy, Commerce, TTS, Studio, and more.

Every call is authenticated and scoped to your workspace, so the agent only ever sees data you can see.

There are two ways to connect, and they expose different tool sets. Pick the one that matches what you need before you wire anything up.

| | Hosted endpoint | Self-run binary | |---|---|---| | How you get it | dst mcp — points your client at Destesi's hosted /mcp endpoint | You run the mcp binary yourself, locally or on your own host | | Setup | One command, nothing to operate | You configure it and keep it running | | Tools | Snap branching (including a SQL query tool), preview environments, and Connect actions | Twelve families: Snap (with fixtures and lineage), Review, Preview, Connect actions, Drive, Deploy, ImageGen, Commerce, TTS, Chat, Studio, Design — about 75 first-party tools. No query tool | | Transport | Streamable HTTP, bearer token per request | stdio (default) or HTTP/SSE |

If you just want an agent that can branch your database and open previews, use the hosted endpoint. If you want an agent that can drive the whole suite, run the binary.

If you have the dst CLI and Claude Code installed, this is the fastest path to first value. It wires you to the hosted endpoint.

  1. Install the CLI (if you haven't already):

    Terminal window
    curl -fsSL https://get.destesi.io/install.sh | sh
  2. Add the Destesi MCP server to Claude Code:

    Terminal window
    dst mcp

    If you aren't logged in yet, dst mcp opens your browser to authenticate first (just like dst login), then registers the server. It wires Claude Code to the hosted MCP endpoint over HTTP with your bearer token attached.

  3. Use it. Open Claude Code and ask your agent to work with your data:

    Clone the production remote into a branch called agent/test, wait for it to be ready, and give me the connection string.

    The agent calls clonewaitremote_url and hands you a live Postgres DSN — backed by copy-on-write, fully isolated from your source.

  • Branch your dataclone a remote or fork a branch into an isolated, copy-on-write copy; branch_list, status, branch_delete; wait blocks until provisioning finishes and remote_url returns the live DSN.
  • Register sourcesremote_add a Postgres database or S3 bucket; remote_list, remote_show, remote_remove.
  • Query a branchquery runs SQL against a ready branch and returns JSON. It runs in a read-only transaction unless you explicitly ask for writes.
  • Read historylog lists a remote's checkpoints (point-in-time history).
  • Drive preview environmentspreview_create, preview_list, preview_status, preview_events, preview_redeploy, preview_delete.
  • Act on your connected apps — one tool per action in Connect's catalog (over 200 actions across around 40 providers), each named connect_{provider}_{action}.

The self-run binary is what you point a desktop client at. It runs over stdio for clients like Claude Desktop and Cursor, and over HTTP/SSE when you want one server to handle several callers. Give it an identity personal access token (PAT) — the same idn_pat_… token dst login stores.

{
"mcpServers": {
"destesi": {
"command": "/path/to/mcp",
"env": {
"DESTESI_API_KEY": "idn_pat_…",
"DESTESI_API_URL": "https://api.destesi.io"
}
}
}
}

The self-run binary registers Snap, Review, and Preview tools unconditionally. Every other family is switched on by setting that product's base URL. Leave a variable unset and the family is simply skipped — the server logs a line and every other family keeps working.

Terminal window
DESTESI_API_URL=https://api.destesi.io \
DESTESI_API_KEY=idn_pat_… \
CONNECT_API_URL=https://api.connect.destesi.io \
DRIVE_API_URL=https://api.drive.destesi.io \
DEPLOY_API_URL=https://api.deploy.destesi.io \
mcp

See the reference for the complete variable list and the tools each family adds.

The MCP server has no consent gate of its own. Tools carry advisory readOnly and destructive annotations that your MCP client can surface before it runs them, but enforcing them is entirely the client's job. One token grants your agent the whole registered surface, and the token is forwarded verbatim to each product — authorization is enforced by the product, not by MCP.

Two practical consequences: treat an identity PAT the way you would treat your own password, and prefer a client that asks before running a write. See CLI & API auth for how tokens are minted and revoked.