Skip to main content
Glama
cr7258

Elasticsearch MCP Server

delete_alias

Remove an alias from a specified Elasticsearch index to streamline index management. Input the index name and alias to delete. Enhances cluster organization and efficiency.

Instructions

Delete an alias for a specific index. Args: index: Name of the index name: Name of the alias

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
indexYes
nameYes

Implementation Reference

  • The MCP tool handler implementation for 'delete_alias'. It is decorated with @mcp.tool(), specifies input parameters (index, name), includes documentation, and delegates execution to the underlying search_client's delete_alias method.
    @mcp.tool() def delete_alias(index: str, name: str) -> Dict: """ Delete an alias for a specific index. Args: index: Name of the index name: Name of the alias """ return self.search_client.delete_alias(index=index, name=name)
  • src/server.py:44-53 (registration)
    Registration of the AliasTools class (containing delete_alias tool) by including it in the tool_classes list passed to ToolsRegister.register_all_tools().
    tool_classes = [ IndexTools, DocumentTools, ClusterTools, AliasTools, DataStreamTools, GeneralTools, ] # Register all tools register.register_all_tools(tool_classes)
  • Underlying client helper method called by the MCP handler, which performs the actual alias deletion via the search engine client API.
    def delete_alias(self, index: str, name: str) -> Dict: """Delete an alias for the specified index.""" return self.client.indices.delete_alias(index=index, name=name)
  • Configuration marking 'delete_alias' as a high-risk operation for the AliasTools class, subject to runtime disabling via environment variables.
    "AliasTools": { "put_alias", "delete_alias", },

Other Tools

Related Tools

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/cr7258/elasticsearch-mcp-server'

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