Skip to main content
Glama
mpeirone

zabbix-mcp-server

template_update

Modify existing Zabbix templates by updating technical name, visible name, or description. Accepts a template ID and returns JSON formatted update results.

Instructions

Update an existing template in Zabbix.

Args:
    templateid: Template ID to update
    host: New template technical name
    name: New template visible name
    description: New template description
    
Returns:
    str: JSON formatted update result

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
descriptionNo
hostNo
nameNo
templateidYes

Implementation Reference

  • The complete implementation of the 'template_update' MCP tool. This handler function is registered via the @mcp.tool() decorator. It performs read-only validation, retrieves the Zabbix API client, constructs update parameters conditionally, calls the Zabbix template.update API method, and returns a formatted JSON response. The function signature and docstring define the input schema.
    @mcp.tool()
    def template_update(templateid: str, host: Optional[str] = None,
                        name: Optional[str] = None, description: Optional[str] = None) -> str:
        """Update an existing template in Zabbix.
        
        Args:
            templateid: Template ID to update
            host: New template technical name
            name: New template visible name
            description: New template description
            
        Returns:
            str: JSON formatted update result
        """
        validate_read_only()
        
        client = get_zabbix_client()
        params = {"templateid": templateid}
        
        if host:
            params["host"] = host
        if name:
            params["name"] = name
        if description:
            params["description"] = description
        
        result = client.template.update(**params)
        return format_response(result)
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 this is an update operation but doesn't mention permission requirements, whether changes are reversible, rate limits, or what happens if only some fields are provided. The return format is mentioned as JSON, but no details about success/error responses are given.

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 well-structured with clear sections for Args and Returns. Each sentence serves a purpose: the first states the tool's function, followed by parameter explanations and return format. It's appropriately sized without unnecessary elaboration.

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

Completeness3/5

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

For a mutation tool with no annotations and no output schema, the description provides basic parameter semantics and return format. However, it lacks important context about authentication requirements, error handling, and behavioral details that would be needed for safe operation. The parameter explanations help, but overall completeness is only adequate.

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 description provides clear semantic explanations for all 4 parameters beyond what the schema offers (which has 0% description coverage). It explains that templateid identifies which template to update, host is the 'technical name', name is the 'visible name', and description is the template description. This adds significant value over the bare schema.

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 verb 'update' and the resource 'existing template in Zabbix', making the purpose specific and understandable. However, it doesn't explicitly differentiate from sibling tools like template_create or template_delete, though the 'existing' qualifier implies it's for modification rather than 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?

No guidance is provided on when to use this tool versus alternatives. While 'existing template' implies it updates pre-existing templates, there's no mention of prerequisites, error conditions, or when to choose template_update over template_create or other template-related tools.

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

Install Server

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/mpeirone/zabbix-mcp-server'

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