getSiteDevicesStats
GET https://{{host}}/api/v1/sites/:site_id/stats/devices
Device Stat Definition
Also see Device Config
Name | Type | Description |
---|
mac | string | device mac |
model | string | device model |
type | string | device type, ap / ble |
serial | string | serial |
version | string | firmware version |
last_seen | long | last seen timestamp |
name | string | device name if configured |
hostname | string | hostname reported by the device |
ip | string | IP address |
ext_ip | string | External / Public IP |
status | string | connected / disconnected / restarting / upgrading |
uptime | long | how long, in seconds, has the device been up (or rebooted) |
num_clients | int | how many wireless clients are currently connected |
tx_bps | float | rate of transmitting traffic to the clients, bits/seconds, last known |
rx_bps | float | rate of receiving traffic from the clients, bits/seconds, last known |
tx_bytes | float | amount of transmitting traffic to the clients, since reboot |
rx_bytes | float | amount of receiving traffic from the clients, since reboot |
tx_pkts | float | amount of transmitting traffic to the clients, since reboot |
rx_pkts | float | amount of receiving traffic from the clients, since reboot |
locating | boolean | whether the device is in locating mode (LED blinking) |
ip_config | object | IP config, see Device Config |
ip_stat | object | current IP information, see Device Config |
module_stat | array | device chassis stats, member index == array index (e.g. member 0 is at index 0) |
if_stat | object | a map of interface stats |
memory_stat | object | memory usage stat (for virtual chassis, memory usage of master RE) |
cpu_stat | object | a map of CPU usage stat |
module_stat.vc_role | string | device chassis stack role (e.g. master/backup) |
ips | object | all IPs the devices has, internal interface name -> CIDR mapping |
radio_config | object | a map of radio config, see Device Config |
led | object | device LED control, see Device Config |
env_stat | object | device environment, including CPU temperature, Ambient temperature, Humidity, Attitude, Pressure, Accelerometers, Magnetometers and vCore Voltage |
locked | boolean | whether this AP is considered locked (placement / orientation has been vetted) |
last_trouble | object | last trouble code of switch |
auto_placement | object | auto placement stats |
has_pcap | boolean | whether the switch supports packet capture |
Radio Config / Status
Name | Type | Description |
---|
radio_stat | object | a map of radio stats, key can be band24 / band5 |
band_24 | object | radio stat of 2.4G radio |
band_5 | object | radio stat of 5G radio |
band_6 | object | radio stat of 6G radio |
mac | string | radio (base) mac, it can have 16 bssids (e.g. 5c5b350001a0-5c5b350001af) |
channel | int | current channel the radio is running on |
bandwidth | int | current channel bandwidth, 20 / 40 / 80 / 160 |
power | int | transmit power (in dBm) |
util_all | int | all utilization in percentage |
util_tx | int | transmission utilization in percentage |
util_rx_in_bss | int | reception of “In BSS” utilization in percentage, only frames that are received from AP/STAs within the BSS |
util_rx_other_bss | int | reception of “Other BSS” utilization in percentage, all frames received from AP/STAs that are outside the BSS |
util_unknown_wifi | int | reception of “No Category” utilization in percentage, all 802.11 frames that are corrupted at the receiver |
util_non_wifi | int | reception of “No Packets” utilization in percentage, received frames with invalid PLCPs and CRC glitches as noise |
util_undecodable_wifi | int | reception of “UnDecodable Wifi” utilization in percentage, only Preamble, PLCP header is decoded, Rest is undecodable in this radio |
dynamic_chaining_enabled | boolean | Use dynamic chaining for downlink |
tx_chain | int | number of chains to use for tx. This is only used when dynamic chaining is not enabled |
rx_chain | int | number of chains to use for rx. This is only used when dynamic chaining is not enabled |
Port Status
Name | Type | Description |
---|
port_stat | objects | ports status |
eth0 | object | port status of eth0 (eth0+PoE) |
eth1 | object | port status of eth1 |
eth2 | object | port status of eth2 |
eth3 | object | port status of eth3 |
module | object | port status of module port |
up | boolean | whether the port is up, default is false (down) |
speed | int | 10 / 100 / 1000 / 2500, Mbps (mega bits per second) |
full_duplex | boolean | true / false |
port_stat
: different type/model of devices may have different number of ports
L2TP Status
Name | Type | Description |
---|
l2tp_stat | objects | l2tp tunnel status (key is the wxtunnel_id) |
wxtunnel_id | string | WxlanTunnel ID |
state | string | idle / wait-ctrl-reply / wait-ctrl-conn / established / establishedwithsessions |
uptime | int | uptime |
sessions | list | list of sessions |
remote_id | string | WxlanTunnel Remote ID (user-configured) |
remote_sid | int | remote sessions id (dynamically unless Tunnel is said to be static) |
local_sid | int | remote sessions id (dynamically unless Tunnel is said to be static) |
LLDP Status
Name | Type | Description |
---|
lldp_stat | objects | LLDP Stat (neighbor information, power negotiations) |
system_name | string | name of the switch, e.g. “TC2-OWL-Stack-01” |
system_desc | string | description provided by switch, e.g. “HP J9729A 2920-48G-POE+ Switch” |
port_desc | string | port description, e.g. “2/20”, “Port 2 on Switch0” |
mgmt_address | string | switch’s management address (if advertised), can be IPv4, IPv6, or MAC |
lldp_med_supported | boolean | whether it support LLDP-MED |
power_request_count | int | number of negotiations, if it keeps increasing, we don’t have a stable power |
power_allocated | int | in mW, provided/allocated by PSE |
power_requested | int | in mW, the current power requested by PD |
power_draw | int | in mW, total power needed by PD |
power_src | string | DC Input / PoE 802.3at / PoE 802.3af / LLDP / ? (unknown) |
power_budget | int | in mW, surplus if positie or deficit if negative |
power_constrained | boolean | whether insufficient power |
power_opmode | string | constrained mode |
BLE Stat
Name | Type | Description |
---|
ble_stat | objects | BLE stats |
tx_pkts | float | TxBytes |
tx_bytes | float | TxCommands |
tx_resets | float | resets due to tx hung |
rx_pkts | float | RxEvents |
rx_bytes | float | RxBytes |
ibeacon_enabled | boolean | Whether iBeacon is Enabled |
ibeacon_uuid | string | UUID value for iBeacon |
ibeacon_major | int | Major number for iBeacon |
ibeacon_minor | int | Minor number for iBeacon |
eddystone_uid_enabled | boolean | Whether Eddystone-UID beacon is enabled |
eddystone_uid_namespace | string | Eddystone-UID namespace |
eddystone_uid_instance | string | Eddystone-UID instance for the device |
eddystone_uid_freq_msec | int | Frequency (msec) of data emmit by Eddystone-UID beacon |
eddystone_url_enabled | boolean | Whether Eddystone-URL beacon is enabled |
eddystone_url_url | string | URL pointed by Eddystone-URL beacon |
eddystone_url_freq_msec | int | Frequency (msec) of data emmit by Eddystone-UID beacon |
Firmware Upgrade Status
Name | Type | Description |
---|
fwupdate | object | last firmware update status |
timestamp | float | timestamp |
status | string | starting / inprogress / success / error |
status_id | int | the internal status id |
progress | int | progress of upgrading expressed in percentage |
Interface Stat
Name | Type | Description |
---|
port_id | string | interface name |
tx_pkts | int | Output packets |
rx_pkts | int | Input packets |
tx_bytes | int | Output bytes |
rx_bytes | int | Input bytes |
up | boolean | whether the port is up, default is false (down) |
CPU Stat
Name | Type | Description |
---|
system | int | Percentage of CPU time being used by system processes |
idle | int | Percentage of CPU time that is idle |
interrupt | int | Percentage of CPU time being used by interrupts |
user | int | Percentage of CPU time being used by user processes |
load_avg | array | Load averages for the last 1, 5, and 15 minutes |
Last Trouble
Name | Type | Description |
---|
code | enum | last trouble code of the switch reported by lldp neighbors |
timestamp | long | timestamp of last trouble code reported |
Trouble Code Possible Values
Code | Description |
---|
102 | No DHCP lease received on any interface |
103 | No default gateway |
104 | Gateway unreachable |
105 | No DNS server |
106 | DNS lookup failed |
108 | Agent cannot connect to controller |
109 | Authentication failed |
110 | Underlying service (i.e. Netconf/SSH/HTTPS) is down |
113 | DNS failure with Mist cloud |
114 | Empty DNS response with Mist cloud |
Autoplacement Stats
Name | Type | Description |
---|
x | float | X Autoplaced Position in pixels |
y | float | Y Autoplaced Position in pixels |
x_m | float | X Autoplaced Position in meters |
y_m | float | Y Autoplaced Position in meters |
status | string | Basic Placement Status |
status_detail | string | Additional info about placement status |
use_auto_placement | boolean | Flag to represent if auto_placement values are currently utilized |
recommended_anchor | boolean | Flag to represent if AP is recommended as an anchor by auto placement service |
info | object | Additional information about auto placements AP data |
Auto Placement Info
Name | Type | Description |
---|
cluster_number | int | All APs sharing a given cluster number can be placed relative to each other |
orientation_state | int | The orientation of an AP |
probability_surface | object | Coordinates representing a circle where the AP is most likely exists in the event of an inaccurate placement result |
Auto Placement Probability Surface
Name | Type | Description |
---|
radius | float | The radius representing placement uncertainty, measured in pixels |
radius_m | float | The radius representing placement uncertainty, measured in meters |
x | float | X-coordinate of the potential placement’s center, measured in pixels |
y | float | Y-coordinate of the potential placement’s center, measured in pixels |
RESPONSES
status: OK
{"mac":"dc38e1dbf3cd","model":"SRX320","type":"gateway","serial":"TC3714190003","last_seen":1553203563,"name":"sj1","hostname":"sj1","status":"connected","version":"18.4R1.8","ip":"10.2.11.137","uptime":13500,"ip_stat":{"ip":"10.2.11.137","netmask":"255.255.192.0","gateway":"10.2.1.1","ip6":"2607:f8b0:4005:808::2004","netmask6":"/32","gateway6":"2607:f8b0:4005:808::1","dns":["8.8.8.8","4.4.4.4"],"dns_suffix":[".mist.local",".mist.com"],"ips":{"vlan1":"10.2.1.1/24,2607:f8b0:4005:808::1/32","vlan193":"10.73.1.31/16","vlan3157":"10.72.11.14/24"}},"cpu_stat":{"interrupt":8,"idle":28,"user":23,"system":41,"load_avg":[0.9700000286102295,1.0499999523162842,1.0199999809265137]},"memory_stat":{"usage":35},"spu_stat":{"cpu":15,"memory":32,"sessions":{"current":41,"valid":15,"pending":12,"max":65535}},"module_stat":[{"vc_role":"master","model":"EX4300-48P","serial":"PX8716230021","fans":[{"name":"Fan 0","status":"absent"},{"name":"Fan 1","airflow":"out","status":"ok"}],"temperatures":[{"name":"CPU","status":"ok","celsius":45.0}],"psus":[{"name":"Power Supply 0","status":"ok"},{"name":"Power Supply 1","status":"failed"}],"poe":{"max_power":250.0,"power_draw":120.3},"vc_links":[{"port_id":"vcp-255/1/0","neighbor_module_idx":1,"neighbor_port_id":"vcp-255/1/0"}],"errors":[{"type":"FW_UPGRADE_REQUIRED_BY_FEATURE","since":1657497600,"feature":"Mist-Management","minimum_version":"128T-6.0.0-1"},{"type":"INACTIVE","since":1657497600},{"type":"HA_FW_MISMATCH","since":1658244424},{"type":"HA_FORMATION_FAILED","since":1658277429,"reason":"config invalid"},{"type":"CONFIG_OUT_OF_SYNC","since":1684825000.123456},{"type":"UNABLE_TO_CONNECT_TO_LOG_SERVER","since":1709203262}]}],"ip2_stat":{},"dhcpd2_stat":{},"cpu2_stat":{},"memory2_stat":{},"spu2_stat":{},"module2_stat":{},"cluster_stat":{"node0":{"status":""},"node1":{"status":""}},"ap_redundancy":{"num_aps":15,"num_aps_with_switch_redundancy":8,"modules":{"1":{"num_aps":15,"num_aps_with_switch_redundancy":8}}}}