Skip to main content
Glama

Netmon (demo)

device_metric_summary

Read-onlyIdempotent

Day / week / month / all-time summary stats for a single device-tracker, by metric type. Multi-backend: pass metric to pick which upstream endpoint to hit.

metric='latency' → wraps POST /api/latency/stats (icmpingId). Returns: dayAvgLatency, weekAvgLatency, monthAvgLatency, allTimeAvgLatency (ms); dayAvgLoss, weekAvgLoss, monthAvgLoss, allTimeAvgLoss (%); dayPingCount/weekPingCount/etc.; dayUptime/weekUptime/etc. (% successful pings); currentLatency, currentLoss, monitoringDuration (humanized).

metric='disk' → wraps POST /api/disk/stats (diskId). Returns: dayGrowthKB, weekGrowthKB, monthGrowthKB, allTimeGrowthKB (negative = filling); estimatedFillTime (humanized projection from 7-day slope); plus current available/used measurements.

This is a fixed-window summary, not time-buckets. Comparing day vs month tells the LLM 'is this metric degrading?'. For the raw samples underneath it, call device_get({id, hours: N, include_logs: true}) — the log rows are opt-in there because they are the expensive half of that response.

Discovery: target_id is a TRACKER id, never a device id, and device_get is the only tool that hands one out. Both sit nested in its response and both survive its default summary shape — they are tracker identity, not log rows, so no flag is needed to see them: latency → device.ping.icmping_id. ping is a single object, not a list: a device has at most one icmping tracker, and its key is icmping_id, not id. disk → device.disks[].id, one entry per monitored volume (agent-collected or SNMP). Most devices carry none — an empty array means there is no disk tracker to summarize, not that the lookup failed.

Port-stats has no equivalent endpoint upstream and is omitted; if one lands later, add a third metric backend.

Permission: devices. Tag-scoped server-side via Devices::withUserTags() before stats are computed.

Examples: device_metric_summary({metric: 'latency', target_id: 17}) device_metric_summary({metric: 'disk', target_id: 42})

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
metricYesWhich metric backend to query: 'latency' (icmping tracker) or 'disk' (disk_servers tracker).
target_idYesTracker id, NOT a device id. For latency it is device.ping.icmping_id from device_get({id}); for disk it is device.disks[].id from the same response. The numbering spaces are unrelated, so passing a device id silently returns whatever tracker happens to hold that id — or a 404 when none does.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description goes far beyond the annotations: it discloses fixed-window vs time-bucket behavior, per-metric return fields, empty-array semantics for disk, tag-scoped permission, and endpoint mapping. Annotations already cover readOnly/idempotent/destructive safety, so the description adds the missing behavioral context rather than contradicting it.

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 front-loaded with a precise summary and then well-delineated sections for metric backends, common discovery pitfalls, alternative usage, and permission. It is long, but most sentences carry unique information; a couple of future-looking or expensive-half remarks are extras the agent could do without.

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

Completeness5/5

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

For a two-backend tool with no output schema, this is very complete: it describes the meaning of each return group, the failure semantics of empty arrays, permission scoping, and the correct way to obtain target_id via device_get. No critical call decision is left to inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Even with 100% schema coverage, the description adds valuable semantics: target_id is explicitly 'a TRACKER id, never a device id', it shows where the id lives in device_get’s response, and warns that passing a device id silently returns the wrong tracker or a 404. The metric parameter is fully mapped to distinct upstream endpoints and return shapes.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence states a specific resource (single device-tracker), a specific operation (summary stats), and the time windows/metric types. It also distinguishes itself from device_get for raw samples and notes the port-stats omission, so an agent can differentiate it from siblings without opening schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives explicit usage context: use this fixed-window summary to assess degradation, and explicitly redirects to device_get for raw log samples underneath it. It also states what upstream endpoints are covered and that port-stats has no equivalent, which are clear when-not conditions.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.