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
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- couchdb_mcp_server.py:322-329 (handler)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 JSONasync 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))]
- couchdb_mcp_server.py:266-267 (registration)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()
- couchdb_mcp_server.py:55-62 (schema)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": {}, }, ),
- couchdb_mcp_server.py:41-46 (helper)Helper method _get_server() that returns the CouchDB server connection, connecting if neededdef _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