Back to Browse

Trino Python MCP Server

Data & AnalyticsLow Risk9.5MCP RegistryLocal
Free

Server data from the Official MCP Registry

Query Trino and inspect or maintain Iceberg tables: catalogs, schemas, SQL, snapshots.

About

Query Trino and inspect or maintain Iceberg tables: catalogs, schemas, SQL, snapshots.

Security Report

9.5
Low Risk9.5Low Risk

Valid MCP server (1 strong, 3 medium validity signals). 1 known CVE in dependencies Package registry verified. Imported from the Official MCP Registry.

9 files analyzed Ā· 2 issues found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

file_system

Check that this permission is expected for this type of plugin.

HTTP Network Access

Connects to external APIs or services over the internet.

env_vars

Check that this permission is expected for this type of plugin.

What You'll Need

Set these up before or after installing:

Trino server hostnameOptional

Environment variable: TRINO_HOST

Trino server portOptional

Environment variable: TRINO_PORT

Trino usernameOptional

Environment variable: TRINO_USER

Trino password (enables basic auth; use with https)Required

Environment variable: TRINO_PASSWORD

http or httpsOptional

Environment variable: TRINO_HTTP_SCHEME

Default catalogOptional

Environment variable: TRINO_CATALOG

Default schemaOptional

Environment variable: TRINO_SCHEMA

Allow only read statements and hide maintenance toolsOptional

Environment variable: TRINO_READ_ONLY

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "mcp-trino-python": {
      "command": "uvx",
      "args": [
        "mcp-trino-python==0.8.2"
      ],
      "env": {
        "TRINO_HOST": "your-trino-host-here",
        "TRINO_PORT": "your-trino-port-here",
        "TRINO_USER": "your-trino-user-here",
        "TRINO_SCHEMA": "your-trino-schema-here",
        "TRINO_CATALOG": "your-trino-catalog-here",
        "TRINO_PASSWORD": "your-trino-password-here",
        "TRINO_READ_ONLY": "your-trino-read-only-here",
        "TRINO_HTTP_SCHEME": "your-trino-http-scheme-here"
      }
    }
  }
}

Some servers take additional arguments. See the repository for details.

Documentation

View on GitHub

From the project's GitHub README.

MCP Trino Server

PyPI Docs Docker License MseeP.ai Security Assessment Badge

Let your AI assistant talk to Trino. Ask questions about your data in plain language; the assistant explores catalogs, writes and runs SQL, and inspects or maintains your Iceberg tables.

Works with Claude Code, Claude Desktop, GitHub Copilot in VS Code, Cursor, and any other MCP client.

šŸ“– Documentation

Quick start

You need uv and a Trino server (or docker run -d -p 8080:8080 trinodb/trino:484 for one with sample data).

Claude Code

claude mcp add trino -e TRINO_HOST=localhost -e TRINO_USER=trino -- uvx mcp-trino-python

or install the plugin, which asks for the connection settings:

/plugin marketplace add alaturqua/mcp-trino-python
/plugin install trino@mcp-trino-python

Claude Desktop

Download mcp-trino-python.mcpb from the latest release and double-click it.

VS Code / GitHub Copilot, Cursor and others

Add this to your client's MCP config (.vscode/mcp.json uses "servers" instead of "mcpServers"):

{
  "mcpServers": {
    "trino": {
      "command": "uvx",
      "args": ["mcp-trino-python"],
      "env": { "TRINO_HOST": "localhost", "TRINO_PORT": "8080", "TRINO_USER": "trino" }
    }
  }
}

Then ask: "What catalogs are in Trino?"

More clients, Docker and troubleshooting: Connect your AI client.

What it can do

  • Explore: catalogs, schemas, tables, columns, DDL and statistics
  • Query: run SQL and get the rows back as JSON
  • Iceberg: snapshots, manifests, partitions, files, history, branches and tags
  • Maintain Iceberg tables: compact files and manifests, expire old snapshots
  • Read-only mode: TRINO_READ_ONLY=true blocks writes and hides maintenance tools

See the full tool list.

Configuration

VariableWhat it doesDefault
TRINO_HOSTTrino server hostnamelocalhost
TRINO_PORTTrino server port8080
TRINO_USERUser to run queries astrino
TRINO_PASSWORDPassword; turns on basic auth (needs https)not set
TRINO_HTTP_SCHEMEhttp or httpshttp
TRINO_CATALOGDefault catalognot set
TRINO_SCHEMADefault schemanot set
TRINO_READ_ONLYtrue blocks writes and hides maintenance toolsfalse

Running a shared server over HTTP or in Docker: see Remote and Docker deployment.

Contributing

uv sync
docker compose up -d --wait trino
uv run pytest

See Development for linting, docs and releases.

License

Apache 2.0. See LICENSE.

Reviews

No reviews yet

Be the first to review this server!