Skip to main content
MCP Toolbox for Databases exposes database tools through MCP. Add Toolbox as a Coral provider so your agents can query your database. You need a running Coral instance and a workspace that you own. Supported databases and query engines include: See Toolbox’s integration catalog for the full list and available tools.

Run Toolbox

  1. Install Toolbox on a host that can reach your database.
  2. For trusted development, choose a prebuilt configuration for your database.
  3. Set the connection and credential environment variables listed in that configuration’s documentation.
For example, after setting the PostgreSQL environment variables, start a local server:
This loads Toolbox’s built-in PostgreSQL tools without a tools.yaml file. For custom tools or databases without a prebuilt configuration, define tools.yaml and use --config tools.yaml instead. Coral recommends exposing only an execute_sql tool, using a database account with the minimum permissions required for your agent’s work. See Toolbox’s security guidance. Its MCP endpoint is http://127.0.0.1:5000/mcp. To expose a specific toolset, use /mcp/<toolset-name> instead. For containers or a remote server, use an address reachable from the Coral runtime. See Deploy with Coral below. Configure database credentials in Toolbox. If Toolbox requires client authentication, follow its authentication documentation and configure the corresponding credentials in Coral.

Add Toolbox to Coral

  1. Open your workspace and select Providers, then Add provider.
  2. Select Add custom and enter the Toolbox endpoint in MCP server URL.
  3. Select Connect.
  4. Set the display name and namespace, then choose the sign-in method that matches your Toolbox configuration.
  5. Select Next. Authenticate if prompted, then review the discovered operations with Expand all.
  6. Select Next, choose the account setting, and select Add provider.
For a server without authentication, select No authentication and confirm No account needed. Review the provider’s operation policy to choose which operations can run or require approval. The database account’s permissions still apply to every query.

Query through Coral

Connect your MCP client to Coral. Give your client the Coral workspace URL, and keep the Toolbox URL in the provider configuration. Ask your agent to query the database using the provider’s namespace.

Deploy with Coral

Without Toolbox client authentication, allow only Coral to reach its MCP endpoint. Direct access bypasses Coral’s operation policy.

Local

Run Toolbox on the same host as Coral with --address 127.0.0.1, as shown above. Use http://127.0.0.1:5000/mcp as the provider URL. Loopback binding blocks remote connections, but other processes on the host can still access Toolbox.

Docker Compose

Follow Toolbox’s Docker Compose guide to add it to your Coral deployment. Connect Coral and Toolbox through a private network shared only by these services. Omit Toolbox’s ports mapping to keep its MCP port unpublished. Keep Toolbox connected to a network that can reach your database. For a service named toolbox on port 5000, use http://toolbox:5000/mcp as the provider URL.

Kubernetes

Follow Toolbox’s Kubernetes guide alongside Coral’s Kubernetes guide. For a sidecar, run Toolbox in Coral’s Pod with --address 127.0.0.1. Use http://127.0.0.1:5000/mcp as the provider URL, without a Service for Toolbox. For a separate Deployment, use an internal ClusterIP Service and a NetworkPolicy that permits inbound connections only from Coral. For a Service named toolbox in the coral namespace, use http://toolbox.coral.svc.cluster.local:5000/mcp. Adjust the namespace, port, and cluster domain to match your deployment. For each deployment, include the provider URL’s hostname and port in Toolbox’s --allowed-hosts. Configure Coral’s outbound permissions for the endpoint in its [outbound] configuration:
  • For loopback HTTP endpoints, including 127.0.0.1 sidecars, set loopback = "http-and-https".
  • For private network HTTP endpoints, including Compose services and Kubernetes ClusterIP Services, set private_networks = "http-and-https".
These permissions are independent and default to deny in server deployments. Desktop and implicit-user local deployments allow both by default, unless you explicitly override them.