Back to Browse

Database MCP Server

Developer ToolsModerate5.5MCP RegistryLocal
Free

Server data from the Official MCP Registry

Give each Holon app a private PostgreSQL store with atomic SQL batches and retry keys.

About

Give each Holon app a private PostgreSQL store with atomic SQL batches and retry keys.

Security Report

5.5
Moderate5.5Moderate Risk

Valid MCP server (4 strong, 1 medium validity signals). 3 known CVEs in dependencies (2 critical, 0 high severity) Imported from the Official MCP Registry.

12 files analyzed · 3 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.

env_vars

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

What You'll Need

Set these up before or after installing:

The Postgres cluster's host, the only one the app may reach.Optional

Environment variable: DATABASE_HOST

The admin role's login name, such as postgres.<branch id> on PlanetScale.Optional

Environment variable: DATABASE_USER

The admin role's password. Each store's password derives from it.Required

Environment variable: DATABASE_PASSWORD

How to Install

Install command not verified. See the repository for install instructions.

View repository

Documentation

View on GitHub

From the project's GitHub README.

Database for Holon

Give each Holon app its own PostgreSQL database and role. The provider identifies the calling app from Holon’s workload identity. The execute tool runs a batch of parameterized statements in one transaction.

Add it to a Holon project

Declare database in the consuming app’s sh.holon.requires metadata in server.json. Add the provider to the same holon.yaml as the calling app. The example pins the published registry version. Replace chat in the caller list with your app’s name.

- name: database
  registry:
    name: io.github.hughhan1/database
    version: "0.1.6"
  access:
    server:
      callers: [chat]

Set DATABASE_HOST and DATABASE_USER on the database app with holon config set. Set DATABASE_PASSWORD with holon secret set. Select the target installation and use --env prod for production values. Deploy the consuming app with holon deploy. Holon finds the provider through the registry, reads its tool contract, and starts it alongside the caller.

Use a dedicated PostgreSQL cluster or branch. The account must be able to create roles and databases, then grant the provisions required by those roles. The provider connects over TLS on port 5432 and verifies the server certificate. Run the provider behind Holon so it receives the authenticated caller identity. Keep direct access to the provider’s container port inside the platform’s trusted network.

Call the database

Pass one SQL statement per item and bind values by name. Holon generates apps.database.tools.execute for apps that declare the dependency.

const { result } = await apps.database.tools.execute({
  statements: [
    {
      sql: "INSERT INTO messages (id, body) VALUES (:id, :body)",
      values: { id: messageId, body: text },
      expect: 1,
    },
    {
      sql: "INSERT INTO agent_jobs (message_id) VALUES (:id)",
      values: { id: messageId },
      expect: 1,
    },
  ],
});

A statement error or an expect mismatch rolls back the batch. Each statement returns column names, rows, and a count of rows returned or changed. The provider accepts up to 100 statements per call and caps each result at 10,000 rows and 4 MiB.

When upgrading to 0.2.0, remove the key argument from tool calls and handle write retry deduplication in the calling app.

This release supports PostgreSQL 16 or later. The tools are intended for the app’s own trusted server code. End users and agents should call the app’s domain tools.

Verify locally

Use Python 3.15, uv, and a disposable PostgreSQL 18 instance on loopback. The tests create isolated roles and databases. Set TEST_DATABASE_URL to the disposable server’s admin URL if it differs from the test default.

uv sync --locked
uv run pytest
holon types generate --contract .

The release workflow generates the Holon tool contract from src/server.py and bundles it with the container image.

Reviews

No reviews yet

Be the first to review this server!