Replies: 3 comments
-
To work with the pagination, you can do: NetboxClientRuby.ipam.ip_addresses.limit(100).offset(100) # addresses 101 - 200
# or
NetboxClientRuby.ipam.ip_addresses.page(0) # first page
|
Beta Was this translation helpful? Give feedback.
-
As for this one:
You're using the API wrong. In you browser, go to But if you go to |
Beta Was this translation helpful? Give feedback.
-
Btw, I'm sorry for the long response time. I did not see that someone opened an issue. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi! First of all, thanks for you library it is really awesome! Everything works nicely.
I'm making OpenStack to NetBox exporter and I want to check if IP address with given IP exists or not. I can obtain all ip addresses and then search if there is object with
address
same as one I obtain from OpenStack but I wonder if there is a way to search for IP with given address. It is not a big issue but requesting couple of thousands IP addresses and search in them is not so effective as one search query.I tried
NetboxClientRuby.ipam.ip_addresses.filter(address: '192.168.4.40/24')
but it doesn't work for me.Pagination also seems to be not documented(just one entry in example config file). It would be really nice to see an example code block about working with pagination IPAM module.
EDIT: Ok, in code I found out that you can use
#all
method to get all objects. But you need to remember to set yourMAX_PAGE_SIZE
to 0 inconfiguration.py
in your NetBox installation if you want to get all objects at once from api.So is it possible?
Beta Was this translation helpful? Give feedback.
All reactions