Skip to main content
Glama
robertoamoreno

CouchDB MCP Server

servidor couchdb-mcp

insignia de herrería

Un servidor de protocolo de contexto de modelo para interactuar con CouchDB

Este es un servidor MCP basado en TypeScript que proporciona herramientas para gestionar bases de datos y documentos de CouchDB. Permite que los asistentes de IA interactúen con CouchDB mediante una interfaz sencilla.

Características

Herramientas

Herramientas básicas (todas las versiones de CouchDB)

  • createDatabase - Crea una nueva base de datos CouchDB

    • Toma dbName como parámetro obligatorio

    • Crea la base de datos si no existe

  • listDatabases - Lista todas las bases de datos de CouchDB

    • Devuelve una matriz de nombres de bases de datos

  • deleteDatabase - Eliminar una base de datos de CouchDB

    • Toma dbName como parámetro obligatorio

    • Elimina la base de datos especificada y todos sus documentos

  • createDocument - Crea un nuevo documento o actualiza un documento existente en una base de datos

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

      • docId : ID del documento

      • data : Datos del documento (objeto JSON)

        • Para actualizaciones, incluya el campo _rev con la revisión actual del documento

    • Devoluciones:

      • Para documentos nuevos: ID del documento y nueva revisión

      • Para actualizaciones: ID del documento y revisión actualizada

    • Detecta automáticamente si la operación es de creación o actualización según la presencia del campo _rev

  • getDocument - Obtener un documento de una base de datos

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

      • docId : ID del documento

    • Devuelve el contenido del documento.

Herramientas de consulta de Mango (solo CouchDB 3.x+)

  • createMangoIndex - Crea un nuevo índice de Mango

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

      • indexName : Nombre del índice

      • fields : Matriz de nombres de campos para indexar

    • Crea un nuevo índice para realizar consultas eficientes

  • deleteMangoIndex - Eliminar un índice de Mango

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

      • designDoc : Nombre del documento de diseño

      • indexName : Nombre del índice

    • Elimina un índice de Mango existente

  • listMangoIndexes : enumera todos los índices de Mango en una base de datos

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

    • Devuelve información sobre todos los índices de la base de datos.

  • findDocuments - Consulta documentos mediante la consulta Mango

    • Parámetros requeridos:

      • dbName : Nombre de la base de datos

      • query : objeto de consulta de Mango

    • Realiza una consulta utilizando la sintaxis de consulta Mango de CouchDB

Related MCP server: MCP Docs RAG Server

Soporte de versiones

El servidor detecta automáticamente la versión de CouchDB y habilita las funciones según corresponda:

  • Todas las versiones: Operaciones básicas de bases de datos y documentos

  • CouchDB 3.x+: Compatibilidad con consultas Mango (índices y consultas)

Configuración

El servidor requiere una URL de conexión y una versión de CouchDB. Estas se pueden proporcionar mediante variables de entorno:

COUCHDB_URL=http://username:password@localhost:5984
COUCHDB_VERSION=1.7.2

You can create a `.env` file in the project root with this configuration. If not provided, it defaults to `http://localhost:5984`.

## Development

Install dependencies:
```bash
npm install

Construir el servidor:

npm run build

Para desarrollo con reconstrucción automática:

npm run watch

Instalación

Instalación mediante herrería

Para instalar couchdb-mcp-server para Claude Desktop automáticamente a través de Smithery :

npx -y @smithery/cli install @robertoamoreno/couchdb-mcp-server --client claude

Para utilizar con Claude Desktop, agregue la configuración del servidor:

En MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json
En Windows: %APPDATA%/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "couchdb-mcp-server": {
      "command": "/path/to/couchdb-mcp-server/build/index.js",
      "env": {
        "COUCHDB_URL": "http://username:password@localhost:5984"
      }
    }
  }
}

Prerrequisitos

  • Node.js 14 o superior

  • Ejecución de una instancia de CouchDB

  • Credenciales de CouchDB adecuadas si la autenticación está habilitada

Depuración

Dado que los servidores MCP se comunican a través de stdio, la depuración puede ser complicada. Recomendamos usar el Inspector MCP , disponible como script de paquete:

npm run inspector

El Inspector proporcionará una URL para acceder a las herramientas de depuración en su navegador.

Manejo de errores

El servidor incluye un manejo robusto de errores para escenarios comunes:

  • Nombres de bases de datos o ID de documentos no válidos

  • La base de datos ya existe/no existe

  • Problemas de conexión

  • Errores de autenticación

  • Datos de documento no válidos

Todos los errores se formatean correctamente y se devuelven a través del protocolo MCP con los códigos de error y mensajes apropiados.

Available Tools

5 tools
createDatabaseC

Create a new CouchDB database

ParametersJSON Schema
NameRequiredDescriptionDefault
dbNameYesDatabase name

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool creates a database but lacks critical details: it doesn't specify if this requires admin privileges, what happens if the database already exists (e.g., error or overwrite), or any rate limits or side effects. This leaves significant gaps for an agent to understand the tool's behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without any wasted words. It's appropriately sized and front-loaded, making it easy for an agent to parse quickly, though it could benefit from more detail given the lack of annotations.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of a database creation tool with no annotations and no output schema, the description is insufficient. It doesn't cover behavioral aspects like permissions, error handling, or what the tool returns upon success. For a mutation tool with zero annotation coverage, more completeness is needed to guide an agent effectively.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with 'dbName' documented as 'Database name'. The description adds no additional meaning beyond this, such as naming conventions, length restrictions, or character constraints. Since the schema does the heavy lifting, the baseline score of 3 is appropriate, but the description doesn't compensate with extra context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Create') and resource ('a new CouchDB database'), making the purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'createDocument' or 'listDatabases', which would require more specificity about what distinguishes database creation from document creation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'createDocument' or 'deleteDatabase'. There's no mention of prerequisites, such as needing admin permissions or checking if a database already exists, nor any explicit exclusions or recommended contexts for usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

createDocumentC

Create a new document or update an existing document in a database

ParametersJSON Schema
NameRequiredDescriptionDefault
dbNameYesDatabase name
docIdYesDocument ID
dataYesDocument data

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. While it mentions the tool can both create and update documents, it doesn't specify whether updates are partial or full replacements, what permissions are required, whether operations are idempotent, or what happens on conflicts. For a mutation tool with zero annotation coverage, this leaves significant behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that clearly states the tool's dual functionality. It's appropriately sized for the tool's purpose without unnecessary elaboration, though it could potentially be more front-loaded with critical behavioral information given the lack of annotations.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a document creation/update tool with no annotations and no output schema, the description is insufficiently complete. It doesn't explain what happens when creating versus updating, what the response looks like, error conditions, or important behavioral constraints. Given the mutation nature and complexity of the operation, more contextual information is needed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, so all three parameters (dbName, docId, data) are documented in the schema. The description doesn't add any meaningful parameter semantics beyond what's already in the schema, such as format requirements for docId or constraints on data structure. This meets the baseline expectation when schema coverage is complete.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with specific verbs ('create' and 'update') and resource ('document in a database'), making it easy to understand what the tool does. However, it doesn't explicitly distinguish this from sibling tools like 'createDatabase' or 'getDocument', which would require more specific differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'createDatabase' for creating databases or 'getDocument' for retrieving documents. There's no mention of prerequisites, error conditions, or typical use cases, leaving the agent with insufficient context for appropriate tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

deleteDatabaseC

Delete a CouchDB database

ParametersJSON Schema
NameRequiredDescriptionDefault
dbNameYesDatabase name to delete

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. It states 'Delete' which implies a destructive mutation, but doesn't disclose critical behavioral traits: whether deletion is permanent, if it requires specific permissions, what happens to contained documents, or error conditions. This is a significant gap for a destructive tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with zero waste. It's appropriately sized and front-loaded, directly stating the tool's purpose without unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given this is a destructive mutation tool with no annotations and no output schema, the description is inadequate. It doesn't explain what happens after deletion (success/failure responses), doesn't warn about irreversible data loss, and doesn't provide context about the CouchDB environment. For a tool that permanently removes resources, this lacks critical completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% (the single parameter 'dbName' is fully described in the schema as 'Database name to delete'). The description doesn't add any parameter meaning beyond what the schema provides, so it meets the baseline of 3 when schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Delete') and target resource ('a CouchDB database'), providing specific verb+resource pairing. It doesn't explicitly distinguish from sibling tools like 'createDatabase' or 'listDatabases', but the verb 'Delete' inherently differentiates it from creation and listing operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided about when to use this tool versus alternatives. The description doesn't mention prerequisites (e.g., database must exist), consequences (e.g., irreversible data loss), or relationships to sibling tools like 'createDatabase' for recreation or 'listDatabases' for verification.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

getDocumentC

Get a document from a database

ParametersJSON Schema
NameRequiredDescriptionDefault
dbNameYesDatabase name
docIdYesDocument ID

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves a document but lacks details on permissions required, error handling (e.g., if the document doesn't exist), response format, or any side effects. This is a significant gap for a read operation in a database context, where such information is crucial for safe usage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without any unnecessary words. It is front-loaded with the core action and resource, making it easy to parse. Every part of the sentence earns its place by conveying essential information, achieving optimal conciseness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of database operations and the lack of annotations and output schema, the description is incomplete. It doesn't address behavioral aspects like error cases, return values, or security requirements, which are critical for an agent to use the tool effectively. The description alone is insufficient for safe and informed tool invocation in this context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with clear documentation for both parameters ('dbName' and 'docId'). The description adds no additional meaning beyond what the schema provides, such as examples or constraints. According to the rules, when schema coverage is high (>80%), the baseline score is 3, which applies here as the description doesn't compensate with extra param details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Get') and resource ('a document from a database'), making the purpose immediately understandable. It distinguishes from siblings like 'createDocument' and 'deleteDatabase' by specifying retrieval rather than creation or deletion. However, it doesn't explicitly differentiate from 'listDatabases' in terms of scope (single document vs. listing databases), which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing an existing database and document), exclusions (e.g., not for creating or deleting), or comparisons to sibling tools like 'listDatabases' for broader queries. This leaves the agent with minimal context for tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

listDatabasesB

List all CouchDB databases

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure. It states what the tool does but doesn't describe how it behaves - no information about pagination, rate limits, authentication requirements, error conditions, or return format. 'List all' implies completeness but doesn't guarantee it.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that states exactly what the tool does with zero wasted words. It's appropriately sized for a simple list operation and front-loads the core functionality.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a read operation with no annotations and no output schema, the description is insufficient. It doesn't explain what the output looks like (array of database names? objects with metadata?), potential limitations, or error handling. The agent would need to guess about the return format and behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters, and schema description coverage is 100% (though empty). The description appropriately doesn't discuss parameters since none exist, earning a baseline score of 4 for tools with no parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List') and target resource ('all CouchDB databases'), providing a specific verb+resource combination. However, it doesn't differentiate from sibling tools like 'getDocument' or 'createDatabase' beyond the obvious scope difference, which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided about when to use this tool versus alternatives. While the purpose is clear, there's no mention of prerequisites, timing considerations, or comparison to sibling tools like 'getDocument' for retrieving specific database information.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

A3.5/5.0
Disambiguation5/5

Each tool has a distinct purpose targeting specific resources and actions: createDatabase, deleteDatabase, and listDatabases handle database-level operations, while createDocument and getDocument handle document-level operations. There is no overlap or ambiguity between tools.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern (e.g., createDatabase, getDocument) using camelCase throughout. The naming is predictable and uniform across all five tools.

Tool Count5/5

With 5 tools, this server is well-scoped for basic CouchDB operations, covering database and document management without being overly sparse or bloated. Each tool serves a clear and necessary function.

Completeness4/5

The toolset covers core CRUD operations for databases (create, delete, list) and documents (create, get), but lacks document deletion and update tools, which are common in database workflows. This minor gap might require workarounds but does not severely hinder functionality.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    B
    quality
    F
    maintenance
    A TypeScript-based MCP server that enables LLM agents to interact with Gel databases through natural language, providing tools to learn database schemas, validate and execute EdgeQL queries.
    2
    13
    12
    ISC
  • F
    license
    A
    quality
    F
    maintenance
    A TypeScript MCP server that allows querying documents using LLMs with context from locally stored repositories and text files through a RAG (Retrieval-Augmented Generation) system.
    4
    17
  • -
    license
    Not graded
    quality
    Not graded
    maintenance
    A TypeScript MCP server that enables AI assistants to create, manage, and manipulate 'crystals' - structured data containers for storing complex analysis, code, and knowledge that can be exported and reimported across different AI conversations.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/robertoamoreno/couchdb-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server