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

New API Endpoint! Org-wide Device Summary

Meraki Employee

New API Endpoint! Org-wide Device Summary

Greetings!

 

We are proud to release a new API endpoint to return the status of all Meraki devices in an organization. It will return an array of objects containing the device details, online status and interface IP addresses.

 

Postman has been updated:

Meraki Dashboard Collection

 

[
  {
    "name":"My AP",
    "serial":"Q2XX-XXXX-XXXX",
    "mac":"00:11:22:33:44:55:66",
    "status":"online",
    "lanIp:"1.2.3.4",
    "publicIp":"4.3.2.1",
    "networkId":"N_1234"
  },
{
"name": MX-abc,
"serial": "Q2QN-WVV9-W4KK",
"mac": "e0:55:3d:17:c6:87",
"publicIp": "64.103.26.54",
"networkId": "L_646829496481095933",
"status": "offline",
"usingCellularFailover": false,
"wan1Ip": "10.10.20.70",
"wan2Ip": null
}, ]

 

Sample Demo 

 

16 REPLIES 16
Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

Looks potentially handy, would it show the status of WAN 1 and WAN 2?  And where did you implement that Sample Demo.  Those style results would be much more useful than a postman dump.  

Adam R MS | CISSP, CISM, VCP, MCITP, CCNP, ITILv3, CMNO
If this was helpful click the Kudo button below
If my reply solved your issue, please mark it as a solution.
Highlighted
Meraki Employee

Re: New API Endpoint! Org-wide Device Summary

Hi Adam,

 

The demo app was written by me using Vue.js & Vuetify with a NodeJS/Heroku backend.

Its in the early stages, but I hope to expand upon it with more examples. 

 

 

Here is the dev work. 

 

Demo: https://meraki-dashboard-pwa-admin.herokuapp.com/

 

GitHub: https://github.com/dexterlabora/meraki-dashboard-pwa-admin

 

Gif Demo:

 

 

Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

This is an excellent start.

 

I somehow wonder if this should be broken out into a separate monitoring API, as opposed to being in the Dashboard API, which is used for provisioning.  I can see the monitoring capabilities being expanded greatly in the future.

 

@Adam you can get info about the uplinks from this function:

https://dashboard.meraki.com/api_docs#return-an-array-containing-the-uplink-information-for-a-device

It has a field "Status".

Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

@DexterLaBora, you'll find one of the top voted requests of all time on the community is for dynamic dashboard monitoring.

https://community.meraki.com/t5/Managed-Services/Need-Dynamic-MSP-Dashboard-Monitoring/m-p/1608

 

It seems a shame that customers need to have to implement this themselves, but so be it.

 

We need the monitoring API to be complete enough to be able to create dynamically updated displays across all organisations.  This new functionality goes a long way towards this.

 

 

I should warn you that this is also likely to result in a large increase in API requests.  I can see most monitoring platforms polling every 60s, and if you get a number of customers doing this, you could get a large increase in API requests.

Highlighted
New here

Re: New API Endpoint! Org-wide Device Summary


I should warn you that this is also likely to result in a large increase in API requests.  I can see most monitoring platforms polling every 60s, and if you get a number of customers doing this, you could get a large increase in API requests.


I disagree that this method would increasing API calls.  I think having this would DECREASE API calls dramatically.  Right now I have to scan through every single device to pull the link information.  It is a very costly API call and do this among multi organizations.  Having a single call that pulls all the information would be extremely useful and much more efficient.  This would decrease thousands of API calls into a single call.  

 

I really hope they expand this to include the link status's, otherwise I am stuck with making thousands of calls ( which sucks with the rate limits ) to understand if any links are down or not.

Highlighted
Here to help

Re: New API Endpoint! Org-wide Device Summary

Looks good, have to check it out!

i was working on a network in org loop, but one call would be preferred !

 

Thanks for the update.

Highlighted
Here to help

Re: New API Endpoint! Org-wide Device Summary


@DonL wrote:

Looks good, have to check it out!

i was working on a network in org loop, but one call would be preferred !

 

Thanks for the update.


So close to having everything I wanted - missing Device type - MX / Z ...

I can wait until Christmas or My Birthday ...

Highlighted
Here to help

Re: New API Endpoint! Org-wide Device Summary

Um....

 

So I am using these two calls:

 

api/v0/organizations/666/inventory

 

api/v0/organizations/666/deviceStatuses

 

And was imagining I would get the same number of Records back for each ?

All Devices are part of the inventory for the Org, no ?

There must be some filtering applied to one call that is not applied to the other!

Could you tell us what it is please ?

 

Thanks,

       Don

Highlighted
Here to help

Re: New API Endpoint! Org-wide Device Summary

Is there a list of the potential return values for status, beyond online?

"status":"online",

 

The docs are generally lacking in detailing all the potential return values. The same is true for the interface status reported as "Active" when querying: 

/api/v0/networks/{{networkId}}/devices/{{serial}}/uplink
Highlighted
Meraki Employee

Re: New API Endpoint! Org-wide Device Summary

I believe it follows the same message as in dashboard:

 

online, offline, or alerting

 

 

 

Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

What do you guys recommend as the easiest platform for building out a dashboard using the APIs.  The more I see the power of the APIs the more I realize I probably ought to start building some stuff in it.  

Adam R MS | CISSP, CISM, VCP, MCITP, CCNP, ITILv3, CMNO
If this was helpful click the Kudo button below
If my reply solved your issue, please mark it as a solution.
Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

If you are referring to a "platform" that you run on your machine (like my backup/restore script) then use Python.  I don't think Python is best, but it is trendier, and as a result, their are a lot more examples.

http://www.ifm.net.nz/cookbooks/meraki-backup.html

 

If you are referring to a server based platform - that is a religious discussion.

 

With regard to Meraki in particular, node.js is very tempting, because it is based on javascript, and you can also use javascript in front end web pages.  Having one language for everything is great.  Also node.js tends to be very light on resources.

 

If you are not so much into coding, then Node-Red is very popular.  It has a GUI and you kinda just link things together.

Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

One more n00b question.  What is the best documentation source for the Meraki APIs?

Adam R MS | CISSP, CISM, VCP, MCITP, CCNP, ITILv3, CMNO
If this was helpful click the Kudo button below
If my reply solved your issue, please mark it as a solution.
Highlighted
Meraki Employee

Re: New API Endpoint! Org-wide Device Summary

Highlighted
Kind of a big deal

Re: New API Endpoint! Org-wide Device Summary

You can also find the public dashboard API here:

https://dashboard.meraki.com/api_docs

Or while logging into the dashboard go:

Help/API Docs

 

Note this is the dashboard API for provisioning.    There is also a captive portal API and a scanning API.

Highlighted
New here

Re: New API Endpoint! Org-wide Device Summary

While this is a step in the correct direction, it doesn't really help much at all until you include the link information.  Being blind to one of the circuits being down isn't really acceptable.  Glad this is being worked on and hopefully it doesn't stop with this function.