cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Search for MAC or IP addr in organization

Highlighted
Comes here often

Search for MAC or IP addr in organization

Perhaps this was done already but I'm looking for an API that can retrieve network id with a given MAC or IP address (WAN/LAN) in organization? Is there such an API?

 

Thanks in advance!

7 REPLIES 7
Highlighted
Kind of a big deal

Re: Search for MAC or IP addr in organization

Nope, that API endpoint does not exist.

 

You'd have to grab every device in the Org (https://api.meraki.com/api_docs#return-the-inventory-for-an-organization) and then grab every client for each device (https://api.meraki.com/api_docs#list-the-clients-of-a-device-up-to-a-maximum-of-a-month-ago) until you find it.

 

Or, you could grab every network in an Org (https://api.meraki.com/api_docs#list-the-networks-in-an-organization) and then list every client in each network (https://api.meraki.com/api_docs#list-the-clients-that-have-used-this-network-in-the-timespan) until you find your client.

 

😞

Highlighted
Getting noticed

Re: Search for MAC or IP addr in organization

I can confirm this does work utilising the method from @jdsilva  I have created a script in powershell that does this but as stated it takes a long time to process.. Which is possibly the way my script is written but it works for searching for mac's at least. I search org > network > device then search for clients on the security appliance. We do have 350 sites to search through. You can take that as a basis on whether it is worth setting up. It has allowed us to find some user's who were serial bandwidth hogs and locate which sites they had been to.  

Highlighted
Meraki Employee

Re: Search for MAC or IP addr in organization

@dbd Could you elaborate on what you are trying to do, create or build with our API? Any details would be appreciated. We're considering a feature that that matches what you're asking for.

Thanks,
Tony
Highlighted
Comes here often

Re: Search for MAC or IP addr in organization

First of all, thanks to everyone's response.

 

@TonyC 

I used Postman to send "API" request to get network information such as networks, devices, static routes, etc. My question: is it possible to create/ build / scripting an API (using Postman if possible)  to obtain network id  info with a given known IP/MAC address within organization? Hope it clear...

 

Thanks.

Highlighted
Getting noticed

Re: Search for MAC or IP addr in organization

This is an older piece of code but should get you what you need. 

 

https://github.com/steinbep/Meraki-API---Python/blob/master/find_machine.py

Highlighted
Comes here often

Re: Search for MAC or IP addr in organization

Thanks @Steinbep . With my very limited knowledge of python I think your recommendation of python script may work. now I gotta go to figure out how to run a python script which i'd never done it before 🙂 .

Highlighted
Getting noticed

Re: Search for MAC or IP addr in organization

@dbd @it will work. It’s what I use. You just need the api key.
 And org id. You can run this from idle or any other ide you want. 

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.