mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
* docs: Continue to reorganize things Make landing pages for /Installation, /API, etc. Split API out into multiple docs Properly use multi-level navigation Add lower nav buttons (tops are bug so disable for now) Add logo for fanciness Refine index page a bit * Improve API TOC layout * Couple of fixes. * Fix API/API-Docs, assumed it was at the right url.
1.0 KiB
1.0 KiB
source: API/ARP.md
list_arp
Retrieve a specific ARP entry or all ARP enties for a device
Route: /api/v0/resources/ip/arp/:ip
- ip is the specific IP you would like to query, if this is all then you need to pass ?device=hostname (or device id)
- This may also be a cidr network, for example 192.168.1.0/24
Input:
- device if you specify all for the IP then you need to populate this with the hostname or id of the device.
Example:
curl -H 'X-Auth-Token: YOURAPITOKENHERE' https://librenms.org/api/v0/resources/ip/arp/1.1.1.1
curl -H 'X-Auth-Token: YOURAPITOKENHERE' https://librenms.org/api/v0/resources/ip/arp/192.168.1.0/24
curl -H 'X-Auth-Token: YOURAPITOKENHERE' https://librenms.org/api/v0/resources/ip/arp/all?device=localhost
Output:
{
"status": "ok",
"err-msg": "",
"count": 1,
"arp": [
{
"port_id": "229",
"mac_address": "da160e5c2002",
"ipv4_address": "1.1.1.1",
"context_name": ""
}
]
}