Skip to content
Last updated

Connecting Cursor to Treasure AI

Connect Cursor to Treasure AI to query databases, build and manage segments in YAML, and debug workflows from Cursor's agent chat, using your existing Cursor plan. This page covers connecting MCP Server (Platform) for platform operations, MCP Server (Docs) for documentation search, and installing TD Skills.

Prerequisites

  • Cursor installed
  • Node.js and npm
  • A Treasure AI account with API access

Connect MCP Server (Platform)

npm install -g @treasuredata/tdx
tdx auth setup

In Cursor, open the command palette (Command + Shift + P on macOS, Ctrl + Shift + P on Windows/Linux), select "Open MCP settings", then "Add custom MCP". Cursor opens mcp.json — add the tdx server:

{
  "mcpServers": {
    "tdx": {
      "command": "tdx",
      "args": ["mcp"]
    }
  }
}

To roll this out to your team, commit the same configuration to .cursor/mcp.json in your repository instead. Each teammate still runs tdx auth setup individually to authenticate.

Connect MCP Server (Docs)

To let Cursor search Treasure AI documentation directly, add a second entry to the same mcp.json:

{
  "mcpServers": {
    "td-docs": {
      "url": "https://docs.treasure.ai/mcp"
    }
  }
}

Install TD Skills

git clone https://github.com/treasure-data/td-skills
mkdir -p ~/.cursor/skills
cp -r td-skills/tdx-skills/* td-skills/sql-skills/* td-skills/workflow-skills/* ~/.cursor/skills/

See TD Skills for the full skill catalog.

Try It

In Cursor's agent chat, confirm the connection appears, then ask a question that requires querying your data:

> List the databases in my Treasure AI environment

Cursor responds with the list of databases from your account, confirming MCP Server (Platform) is connected.

Next Steps