================== /// MCP /// /// MCP /// ================== [server:online] [protocol:ready]
mcp-trino
by tuannvm
High-performance Model Context Protocol (MCP) server that exposes Trino’s distributed SQL engine through STDIO and HTTP/StreamableHTTP transports with optional OAuth/JWT authentication.
48
15
Open Source01
execute_query
Execute a SQL query against Trino with full SQL support for complex analytical queries.
02
list_catalogs
List all catalogs available in the Trino server.
03
list_schemas
List all schemas within a specified catalog.
04
list_tables
List all tables within a specified catalog and schema.
05
get_table_schema
Retrieve the column definitions (name, type, nullability) of a specified table.
Installation
1. Prerequisites
• Go 1.21 or newer, GOPATH correctly configured.
• A reachable Trino cluster (host, port and user credentials).
• (Optional) Docker if you prefer containerised deployment.
2. Fetch source & build binary
git clone https://github.com/tuannvm/mcp-trino.git
cd mcp-trino
# Build in-tree
go build -o bin/mcp-trino ./cmd/mcp-trino
# Or install globally (adds to $(go env GOPATH)/bin)
go install github.com/tuannvm/mcp-trino/cmd/mcp-trino@latest
3. Minimal configuration
Create a YAML or JSON config (examples are in the `configs/` folder of the repo):
server:
host: 0.0.0.0
port: 7080 # MCP listening port
trino:
host: trino.company.local
port: 8080
catalog: hive
user: mcp
Or supply the same values via environment variables:
MCP_SERVER_HOST=0.0.0.0
MCP_SERVER_PORT=7080
TRINO_HOST=trino.company.local
TRINO_PORT=8080
TRINO_CATALOG=hive
TRINO_USER=mcp
4. Run the server
./bin/mcp-trino --config ./config.yml # file-based
# or rely on env variables only
./bin/mcp-trino
5. Docker (optional)
docker build -t tuannvm/mcp-trino .
docker run -d -p 7080:7080 \
-e TRINO_HOST=trino.company.local \
tuannvm/mcp-trino
6. Verifying
Once running, the server exposes its MCP endpoint on the configured port. Use an MCP client or `grpcurl` to call `ListModels` to verify connectivity.
Documentation
License: Not specified (no license field detected in repository metadata)
Updated 7/30/2025