update-connection-settings
Modify Meilisearch connection settings, including URL and API key, to ensure proper integration with LLM interfaces via the MCP server.
Instructions
Update Meilisearch connection settings
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| api_key | No | ||
| url | No |
Implementation Reference
- src/meilisearch_mcp/server.py:476-485 (handler)Handler logic in the call_tool method that matches the tool name and calls update_connection with arguments, then returns success message.elif name == "update-connection-settings": self.update_connection( arguments.get("url"), arguments.get("api_key") ) return [ types.TextContent( type="text", text=f"Successfully updated connection settings to URL: {self.url}", ) ]
- src/meilisearch_mcp/server.py:84-95 (registration)Tool registration in list_tools decorator, including name, description, and input schema definition.types.Tool( name="update-connection-settings", description="Update Meilisearch connection settings", inputSchema={ "type": "object", "properties": { "url": {"type": "string"}, "api_key": {"type": "string"}, }, "additionalProperties": False, }, ),
- src/meilisearch_mcp/server.py:55-66 (helper)Helper method that performs the actual connection update by setting new URL/API key and reinitializing MeilisearchClient and ChatManager.def update_connection( self, url: Optional[str] = None, api_key: Optional[str] = None ): """Update connection settings and reinitialize client if needed""" if url: self.url = url if api_key: self.api_key = api_key self.meili_client = MeilisearchClient(self.url, self.api_key) self.chat_manager = ChatManager(self.meili_client.client) self.logger.info("Updated Meilisearch connection settings", url=self.url)