Coremcp logo

Coremcp

by corebasehq

Connects MSSQL and PostgreSQL databases to MCP clients with schema tools, query controls, PII masking, and local or WebSocket operation.

Install Coremcp

Run the project’s own setup commands, in order.

Setup steps from the project

corebasehq/coremcp installs with its own steps rather than a config we can generate, so these are copied as-is. Follow them in order and run the commands in a terminal. Source: github.com

  1. 1. Install
    curl -fsSL https://get.corebasehq.com | sh
    
  2. 2. Install
    docker pull y11t0/coremcp:latest
    
  3. 3. Install
    git clone https://github.com/corebasehq/coremcp.git
    
  4. 4. Install
    cd coremcp
    
  5. 5. Install
    go build -o coremcp ./cmd/coremcp
    
  6. 6. Add to your MCP client
    ./coremcp connect \
      --server="wss://api.corebasehq.com/ws/agent" \
      --token="sk_xxx" \
      --agent-id="site-istanbul-001" \
      --max-reconnect=0
    

Overview

The corebasehq/coremcp MCP server exposes MSSQL and PostgreSQL databases as MCP tools from a Go binary. It supports local stdio use with clients such as Claude Desktop and outbound WebSocket connections for databases behind NAT. Read-only mode is enabled by default, while query validation, row limits, and configurable PII masking reduce exposure risks. Reach for it when an agent needs controlled access to localhost or on-premise database data and schema information.

Use cases

  • Query on-premise MSSQL data from an MCP client
  • Inspect tables and stored procedure schemas
  • Run read-only SQL with row limits and PII masking
  • Connect databases behind NAT through an outbound WebSocket

Key features

  • MSSQL and PostgreSQL adapters
  • Schema and stored procedure discovery
  • Read-only mode by default
  • AST-aware SQL safety checks
  • Configurable row limits and PII masking
  • stdio and outbound WebSocket transports

Tools6

What Coremcp lets your agent do. Expand a tool for its parameters.

Self-reported~124 tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

18/18 checks healthy over the last 117d

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars12Stargazers on the source repository.
Last commit4mo agoMost recent push to the default branch.
Tools exposed6Callable tools this server registers over MCP.
Directory activity3 viewsConfig copies, upvotes, and views on AllMCPs.

How Coremcp works

What corebasehq/coremcp MCP server does

The corebasehq/coremcp MCP server connects MCP clients to configured SQL data sources. Its stable database adapters are MSSQL and PostgreSQL, with a dummy adapter available for testing without a real database. The project is distributed as a Go binary that includes its database drivers.

Agents can run SQL against a named source and inspect database structure. Schema discovery includes tables, columns, primary and foreign key information, views, and stored procedures. Procedure metadata includes parameter names, types, modes, and an example call. Calling a stored procedure is available only when the source explicitly sets readonly: false.

How it works

Local operation uses the serve command and stdio transport. This is intended for desktop MCP clients and other local processes. Remote operation uses connect, which opens an outbound WebSocket to a relay.

The corebasehq/coremcp MCP server applies security processing before and after database access. Its T-SQL-aware validation allows SELECT and WITH statements in read-only query mode and rejects disallowed statements, multiple statements, and several SQL Server features that could modify or expose data. A forced row limit caps result size, and regex-based masking can replace configured patterns such as email addresses, credit card numbers, and Turkish identity numbers in returned strings.

MSSQL sources can optionally use READ UNCOMMITTED behavior through no_lock. The normalize_turkish option supports selected legacy Turkish database encoding and comparison cases, including normalization of SQL string literals and correction of some mojibake in returned text.

Setup and configuration

Install options include a release binary, the Linux/macOS installer, Docker, or building from source with Go 1.23 or newer. A YAML file named coremcp.yaml is used by the local server. Each source requires a unique name, adapter type, and database connection string. MSSQL uses a sqlserver:// DSN; PostgreSQL uses a postgresql:// DSN.

The default source setting is read-only. Set readonly: false only when procedure execution is needed, and use a database account limited to the intended SELECT and EXECUTE permissions. Server settings also control logging, transport, port, row limits, PII masking, and custom masking patterns.

For remote mode, provide a relay WebSocket URL and authentication token to coremcp connect. An agent ID can be supplied for identification, and reconnect behavior can be configured with command-line flags.

Tools and capabilities

The corebasehq/coremcp MCP server provides these database tools:

  • query_database runs SQL against a selected configured source.
  • list_tables reports tables, column counts, primary keys, and foreign key counts.
  • describe_table returns detailed column and constraint metadata, including comments.
  • list_views returns views and their column definitions.
  • list_procedures returns stored procedure parameters and example calls.
  • execute_procedure invokes a procedure with named parameters when writes are enabled for that source.

The remote relay protocol additionally supports SQL execution, cached schema retrieval, source listing, health checks, and configuration synchronization.

Limitations and notes

Firebird support is still in progress and currently returns a placeholder error. MySQL is listed as roadmap work, while HTTP transport, audit logging, and query-result caching are also not yet available. Query safeguards are intended as one security layer; the documentation recommends pairing them with least-privilege database roles rather than relying on validation alone. no_lock can produce dirty reads, so it should be used with that trade-off understood.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Coremcp

Download a release binary, use the Linux/macOS installer, pull the Docker image, or build from source with Go 1.23 or newer.

Yes. The server supports local stdio mode, and the README provides a Claude Desktop configuration using the `serve` command.

Stable adapters are available for MSSQL and PostgreSQL. A dummy adapter is available for testing; Firebird is in progress and MySQL is on the roadmap.

Yes. Omitting `readonly` leaves SELECT-only mode active. Setting `readonly: false` enables the `execute_procedure` tool.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewCoremcp AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/corebasehq-coremcp?style=directory)](https://allmcps.com/mcp/corebasehq-coremcp)
HTML Embed
<a href="https://allmcps.com/mcp/corebasehq-coremcp"><img src="https://allmcps.com/api/badge/corebasehq-coremcp?style=directory" alt="Coremcp on AllMCPs" /></a>