Way to search a network by name instade of ID

Solved
Lagorce_JB
Conversationalist

Way to search a network by name instade of ID

Hi,

Is there a way to get the ID of a network if have the Organisation ID and the Name ?

We have thousands of networks so it take to long to get all and check in the Json Resluts ...

Thanks for your helps 🙂

1 Accepted Solution
JacobRussell
Conversationalist

I don't think there is a way to do this unfortunately.

 

One way I have gotten around it a bit is to periodically retrieve all the networks, and store a dictionary of names and IDs. If you have a way to quickly retrieve the dictionary from some sort of storage (S3 for example if you use AWS) you can quickly get the IDs by name then call the /networks/{networkId} endpoint.

 

There's trade-offs of course, especially depending on how often you update your dictionary. Hope that helps a little!

View solution in original post

3 Replies 3
JacobRussell
Conversationalist

I don't think there is a way to do this unfortunately.

 

One way I have gotten around it a bit is to periodically retrieve all the networks, and store a dictionary of names and IDs. If you have a way to quickly retrieve the dictionary from some sort of storage (S3 for example if you use AWS) you can quickly get the IDs by name then call the /networks/{networkId} endpoint.

 

There's trade-offs of course, especially depending on how often you update your dictionary. Hope that helps a little!

Thanks for the reply that what we do.

Hop one day Meraki will add the search by name. like on dashboard.

We will win some API call :).

 

 

Agreed. My api script, you have to foreach ($org in $orgs) then foreach ($network in $networks) which takes many, MANY API calls. 

 

I have over 60 orgs+ 250+ networks and this takes about 1-2 minutes. 

 

Better to store the value in a file somewhere to search manually if you need to. 

 

You can always export-csv and sort per your own parameters. 

 

 

Get notified when there are additional replies to this discussion.
Welcome to the Meraki Community!
To start contributing, simply sign in with your Cisco account. If you don't yet have a Cisco account, you can sign up.