09-21-2015 08:06 AM
Hi,
I'm using Cisco Prime Infrastructure 2.2 and I'm trying to get some info from the API in order to build a template.
But I can't find how to get all the interfaces' name from a device IP. I tried many queries but none of them returned what I expect. Is there a way the interfaces?
Thank you.
Guillaume.
Solved! Go to Solution.
09-21-2015 08:16 AM
Hello, doesn't "GET InventoryDetails" give you what you need? I believe you can use the capabilities of REST to filter it down to only the devices you are interested in.
09-21-2015 08:16 AM
Hello, doesn't "GET InventoryDetails" give you what you need? I believe you can use the capabilities of REST to filter it down to only the devices you are interested in.
09-22-2015 01:06 AM
Hi Scott,
Thanks to you I figured it out !
Here is what I did :
1st - Get all the devices id
You can call either /webacs/api/v1/data/Devices or /webacs/api/v1/data/InventoryDetails
2nd - Get info from each device
Call /webacs/api/v1/data/InventoryDetails/1234 <-- Device Id
And you get all the interfaces name, duplex mode, interface index, neighbors, VLan, ...
Thanks again !
Guillaume.
09-24-2015 05:35 AM
Terrific! It seems that the PI API is still new enough that there aren't a lot of people out there using it yet. I was looking for a forum specifically dedicated to the PI, and I found one in the Developer community:
That community seems to have at least one Cisco resource who is fairly responsive and knowledgeable. Keep an eye out there for helpful stuff.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide