mcpField
C
Couchbase

Couchbase

Local
github.com/hummusonrailsDatabases1Updated 83w ago

About Couchbase

Couchbase is an MCP server that lets MCP clients query Couchbase Capella clusters using natural-language requests. It runs SQL++ queries through the Couchbase Node.js SDK and returns the results.

Key features

  1. 01Execute SQL++ queries
  2. 02Connect to Couchbase Capella clusters
  3. 03Return query results to MCP clients

Use cases

  1. 01Retrieve documents matching a request
  2. 02Query selected fields with filters
  3. 03Get recent documents from a bucket

MCP support

It exposes a `query-couchbase` tool that executes SQL++ statements on a Couchbase Capella cluster and returns results to MCP clients.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"couchbase": {
"command": "npx",
"args": [
"-y",
"couchbase-mcp-server"
],
"env": {
"COUCHBASE_CONNECTION_STRING": "<COUCHBASE_CONNECTION_STRING>",
"COUCHBASE_USERNAME": "<COUCHBASE_USERNAME>",
"COUCHBASE_PASSWORD": "<COUCHBASE_PASSWORD>"
}
}
}
}
Run commandnpx -y couchbase-mcp-server
Environment variables to set
COUCHBASE_CONNECTION_STRING
COUCHBASE_USERNAME
COUCHBASE_PASSWORDSecret

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npmcouchbase-mcp-server

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Couchbase MCP Server

The Model Context Protocol (MCP) is a protocol for handling interactions between large language models (LLMs) and external systems. This repository implements a Couchbase MCP Server using the Couchbase Node.js SDK, enabling MCP clients (e.g., Claude Desktop) to perform natural language queries on Couchbase Capella clusters.

With this server you can use commands like:

  • Show me the results of SELECT * FROM my_bucket LIMIT 10
  • Execute this query: SELECT name, age FROM users WHERE active = true
  • Get me the latest 5 documents from my_bucket
  • Summarize the latest 5 orders from the orders bucket for me

Example

The following screenshot shows the MCP server in action with the Claude Desktop client. The user issues a general request in plain English and the MCP server translates it into a SQL++ query that is executed against the Couchbase Capella cluster. The results are then returned to the user in a readable format.

Example Screenshot of the MCP server working in Claude

Setup

  1. Clone the repository and install dependencies:
git clone [email protected]:hummusonrails/couchbase-mcp-server.git
cd couchbase-mcp-server
npm install
  1. Create a .env file in the root directory and add your Couchbase connection string, username, and password:
COUCHBASE_CONNECTION_STRING=couchbases://your-cluster.cloud.couchbase.com
COUCHBASE_USERNAME=your_username
COUCHBASE_PASSWORD=your_password

Refer to the .env.sample file for the required environment variables.

  1. Build the project:
npm run build
  1. Run the server using Stdio transport:
npx couchbase-mcp-server

Note

The MCP server uses the StdioServerTransport, so it communicates over standard input/output. Ensure that your MCP client (e.g., Claude Desktop) is configured to use a local MCP server. Follow the Claude Desktop documentation to set up the MCP client to connect to the local server.

Features

Couchbase Query Tool
  • ToolName: query-couchbase
  • Description: Executes a SQL++ query statement on your Couchbase Capella cluster.
  • Usage: When invoked, the server will use the Couchbase Node.js SDK to execute the provided SQL++ query and return the results.

Developing

To work on the project locally:

  1. Install dependences:
npm install
npm run build
  1. Test the server using an MCP client:

Launch your MCP client (e.g., Claude Desktop) configured to connect and invoke the tool using a sample query.

  1. Debugging

All logging messages are sent to stderr to ensure that stdout only contains MCP protocol JSON. Check your logs for detailed connection and error messages.

Contributing

Contributions are welcome! Please feel free to submit a pull request or open an issue with your suggestions. For any changes, ensure you follow the project’s code style.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.