A ticket records a known problem: title, area, hosts, subject, description, links to alert rules and anomalies, and a log of comments, edits, resolving and reopening. Opening, resolving (with the resolution as the note) and reopening go on the timeline; every step is audited, and the audit rows stay off the timeline. An alert or anomaly an open ticket covers (by link, by subject, or a host-wide ticket on the host itself) shows a Known issue badge, and offers "Open a ticket" prefilled from its rule or anomaly when none does. Hosts, monitors and containers get a Known issues card. MCP: list_tickets, get_ticket (viewer); open_ticket, update_ticket, comment_ticket, resolve_ticket, reopen_ticket (operator). list_alerts and list_anomalies carry known_issue; get_overview, get_host, get_monitor and get_container carry open_tickets. Also update_change and delete_change for changes recorded by hand (author or admin). Tickets are left out of backups, like the timeline (2026-10-15 ruling). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
25 lines
1.0 KiB
Python
25 lines
1.0 KiB
Python
"""Core MCP tool modules.
|
|
|
|
Each module defines plain `async def` tools at module level (tests call them
|
|
directly) and a `register(register_tool)` that lists them with their minimum
|
|
role. `register_tool(fn, role=..., read_only=...)` takes both as required
|
|
keywords: a tool with no declared role is unreachable, and there is no default
|
|
read_only for a mutating tool to inherit by forgetting.
|
|
|
|
A tool's docstring IS its contract with the agent — it ships as the tool's
|
|
description. Say what it is for, when to reach for it over its siblings, what
|
|
each argument's empty value means, and what comes back.
|
|
"""
|
|
from __future__ import annotations
|
|
|
|
from . import (alerts, anomalies, audit, automation, backups, hosts, metrics, monitors, overview, session,
|
|
tickets, timeline)
|
|
|
|
_MODULES = (session, overview, hosts, monitors, alerts, anomalies, metrics, audit, timeline, tickets,
|
|
automation, backups)
|
|
|
|
|
|
def register_all(register_tool) -> None:
|
|
for module in _MODULES:
|
|
module.register(register_tool)
|