item_update
Modify Zabbix monitoring items by updating their name, key, update interval, or status using the item_update tool on the zabbix-mcp-server.
Instructions
Update an existing item in Zabbix.
Args:
itemid: Item ID to update
name: New item name
key_: New item key
delay: New update interval
status: New status (0=enabled, 1=disabled)
Returns:
str: JSON formatted update result
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| delay | No | ||
| itemid | Yes | ||
| key_ | No | ||
| name | No | ||
| status | No |
Input Schema (JSON Schema)
{
"properties": {
"delay": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Delay"
},
"itemid": {
"title": "Itemid",
"type": "string"
},
"key_": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Key"
},
"name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Name"
},
"status": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Status"
}
},
"required": [
"itemid"
],
"type": "object"
}
Implementation Reference
- src/zabbix_mcp_server.py:411-442 (handler)The handler function for the item_update MCP tool. It updates Zabbix item properties like name, key, delay, and status using the Zabbix API client.@mcp.tool() def item_update(itemid: str, name: Optional[str] = None, key_: Optional[str] = None, delay: Optional[str] = None, status: Optional[int] = None) -> str: """Update an existing item in Zabbix. Args: itemid: Item ID to update name: New item name key_: New item key delay: New update interval status: New status (0=enabled, 1=disabled) Returns: str: JSON formatted update result """ validate_read_only() client = get_zabbix_client() params = {"itemid": itemid} if name: params["name"] = name if key_: params["key_"] = key_ if delay: params["delay"] = delay if status is not None: params["status"] = status result = client.item.update(**params) return format_response(result)