list_backups, check_backup and make_backup are Settings → Backups for an agent, admin only like the page. make_backup runs the page's job in the background and is audited as "<user> via MCP". Restoring stays in the browser. get_overview names a scheduled backup that failed, is two hours past its slot, or has no bucket. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
24 lines
974 B
Python
24 lines
974 B
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
|
|
|
|
_MODULES = (session, overview, hosts, monitors, alerts, anomalies, metrics, audit, automation,
|
|
backups)
|
|
|
|
|
|
def register_all(register_tool) -> None:
|
|
for module in _MODULES:
|
|
module.register(register_tool)
|