I'm using the REST API to generate a custom report. This report needs to show the cid and type of each circuit connected to a router in our organization.
To get this info I took these steps:
- GET all devices with role id of "router";
- Iterate the router list;
- GET all interfaces for each router device_id;
- Iterate the interface list;
- If that interface is connected to a circuit, GET the circuit info.
Depending on the number of routers and interfaces, I'll be bombarding the server with hundreds of requests.
I tried to reduce the number of requests in step 2/3 above by filtering the interface request passing various device_id:
According to the docs, using repeating filter parameters should work (
https://netbox.readthedocs.io/en/stable/api/overview/#filtering), however the above request only returns the interfaces from the last device_id passed (1200).
I tested some requests with repeated filter parameters, and it seems to work for some parameters, but not for others.
Is this a bug? Or is there some restriction of which parameters can be passed multiple times to filter a request?
I'm running netbox v2.5.8
Thanks for any help.