Skip to main content
Glama
andyfe76

CouchDB MCP Server

by andyfe76

couchdb_list_databases

Retrieve a list of all databases available in your CouchDB server for database management and administration tasks.

Instructions

List all databases in the CouchDB server

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function _list_databases() that executes the tool logic - retrieves all databases from the CouchDB server, formats the result with count, and returns as JSON
    async def _list_databases(self) -> list[TextContent]: """List all databases.""" databases = list(self._get_server()) result = { "databases": databases, "count": len(databases) } return [TextContent(type="text", text=json.dumps(result, indent=2))]
  • Registration in call_tool() - maps the tool name 'couchdb_list_databases' to its handler method _list_databases()
    if name == "couchdb_list_databases": return await self._list_databases()
  • Tool schema definition - declares the tool name, description, and input schema (empty object, no parameters required)
    Tool( name="couchdb_list_databases", description="List all databases in the CouchDB server", inputSchema={ "type": "object", "properties": {}, }, ),
  • Helper method _get_server() that returns the CouchDB server connection, connecting if needed
    def _get_server(self) -> couchdb.Server: """Return the CouchDB server, connecting if needed.""" if self.couch is None: self.connect() assert self.couch is not None return self.couch

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/andyfe76/couchdb_mcp'

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