get_port_traffic
Retrieve current and historical traffic statistics for a network port to monitor bandwidth, utilization, and diagnose congestion or capacity issues.
Instructions
Get detailed traffic statistics for a specific network port.
Returns current bandwidth rates and historical statistics including peak and average utilization. Essential for capacity planning and troubleshooting.
RETURNS:
port_id, hostname, name, alias, speed
admin_status, oper_status
current:
in_rate_bps, out_rate_bps: Current traffic rate in bits/sec
in_utilization_pct, out_utilization_pct: Current % of port capacity
total_in_octets, total_out_octets: Lifetime byte counters
historical (when RRD data available):
period: Time range analyzed
statistics.in: peak_bps, peak_mbps, avg_bps, avg_mbps, peak_utilization_pct
statistics.out: peak_bps, peak_mbps, avg_bps, avg_mbps, peak_utilization_pct
PERIODS: 1h (hour), 6h (6 hours), 1d (day), 1w (week), 1m (month)
EXAMPLE QUESTIONS:
"What's the current bandwidth on port 211?"
"What was peak utilization on the Internet port this week?"
"Show traffic trends for the uplink over the past month"
"Is the WAN link congested?"
TIP: Use list_ports first to find the port_id, or specify device_hostname + port_name
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_port_traffic"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| period | No | Time period for historical statistics | 1d |
| port_id | No | The port ID (get from list_ports) | |
| port_name | No | Port name like 'GE0/0/1', 'eth0', or description like 'Internet' | |
| device_hostname | No | Device hostname (use with port_name if port_id unknown) |