Get the FREE Ultimate OpenClaw Setup Guide →

tailpipe

Enable AI assistants to explore and query your Tailpipe data!

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio turbot-tailpipe-mcp npx -y @turbot/tailpipe-mcp \
  --env TAILPIPE_MCP_LOG_LEVEL="Logging level (debug|info|warn|error, default: info)" \
  --env TAILPIPE_MCP_MEMORY_MAX_MB="Maximum memory for command execution in MB (optional)" \
  --env TAILPIPE_MCP_INIT_SCRIPT_PATH="Path to the Tailpipe init SQL script (optional, if not provided in args)"

How to use

Tailpipe MCP exposes a set of read-only database and source operations that connect your AI assistant to your Tailpipe-driven log data. Once configured, you can prompt the AI to explore CloudTrail, Kubernetes, and other log sources, run read-only Tailpipe SQL queries, and inspect data structures such as partitions and tables. The available tools include tailpipe_query for executing SQL against Tailpipe data, along with tailpipe_connect to initialize or refresh the DuckDB session from your Tailpipe init script. You can also enumerate and inspect Tailpipe sources, plugins, and tables to understand what data is accessible. Use natural language queries to request specific events, timelines, costs, or security investigations, and let the MCP translate your intent into Tailpipe SQL under the hood. To begin, ensure the MCP server is running and your Tailpipe environment is properly installed and configured. Then, in your AI assistant’s MCP configuration, point to the tailpipe MCP server and, if needed, supply a path to your Tailpipe init script. You can test basic queries such as listing available tables or retrieving recent CloudTrail events to verify connectivity before proceeding with complex analyses.

How to install

Prerequisites:

  • Node.js v16 or higher (includes npx)
  • Tailpipe installed and configured

Installation steps:

  1. Install dependencies and build the MCP server package:
git clone https://github.com/turbot/tailpipe-mcp.git
cd tailpipe-mcp
npm install
npm run build
  1. Run the MCP server using npx (as shown in the configuration example):
# Example with default init script discovery
npx -y @turbot/tailpipe-mcp
  1. If you want to run directly via Node.js for local testing, use the recommended approach shown in the repository’s testing guide:
{
  "mcpServers": {
    "tailpipe": {
      "command": "node",
      "args": [
        "/absolute/path/to/tailpipe-mcp/dist/index.js",
        "/path/to/your/tailpipe_init_YYYYMMDDHHMMSS.sql"
      ]
    }
  }
}
  1. Optional: validate with the MCP Inspector:
npx @modelcontextprotocol/inspector dist/index.js

Notes:

  • The Tailpipe CLI/init script is required or supplied via the init_script_path argument or environment variable.
  • If you are developing locally, you can point the MCP to a local dist/index.js build as demonstrated above.

Additional notes

Environment variables to consider:

  • TAILPIPE_MCP_INIT_SCRIPT_PATH: Path to your Tailpipe init SQL script (alternative to command-line args)
  • TAILPIPE_MCP_LOG_LEVEL: Logging level (debug|info|warn|error)
  • TAILPIPE_MCP_MEMORY_MAX_MB: Memory cap for command execution (in MB) Common issues:
  • Ensure Tailpipe CLI is installed and configured before starting the MCP server.
  • If using npx, the package @turbot/tailpipe-mcp must be available in the npm registry and accessible.
  • When pointing to a specific init script, provide an absolute path to avoid path resolution issues.
  • Restart the AI assistant after updating the MCP configuration for changes to take effect.

Related MCP Servers

Sponsor this space

Reach thousands of developers