Dashboard API Query

jashcraft
Just browsing

Dashboard API Query

I'm using networks/n_id/clients/?timespan=7200 to look at clients that have associated with this network over the last 2 hours.

When I run this I only receive 4 clients back - but when I check the dashboard for clients associated within the last 2 hours on the network I see 10.

 

Am I interpreting what this api query looks for/or am I using timespan wrong in this instance?

3 REPLIES 3
LearningIsFun
Conversationalist

I have found this call only provides clients from "network" ie the Security Appliance.  Where if you are looking at the Dashboard - Network-Wide - Clients default view without a filter, then you are seeing clients across all the devices in that network.  You may see clients for example that have talked on a switch but not passed enough/any traffic through the appliance to show there.

 

On the Clients page you can filter to, Only security appliance clients, or switch, or access points. etc.

Inderdeep
Kind of a big deal

@jashcraft : Not sure if it helps 

https://community.meraki.com/t5/Developers-APIs/Timespan-portion-of-Network-client-APIs-seems-to-be-...

 

Regards
Inderdeep Singh
www.thenetworkdna.com ( Awarded by Cisco IT Blogs award 2020)
ShawnHu
Meraki Employee

@jashcraft  I just randomly ran the same call on multiple networks across different organizations, I have seen a consistent number of clients from both API and dashboard.  

From your original message, although I didn't expect a slash between 'clients and the question mark as highlighted in red below, actually it worked for me with or without that slash. 

'"networks/n_id/clients/?timespan=7200

 

I would suggest double-checking the network ID, trying the curl command to rule out any SDK/tool dependency, and also trying to see if you can get more clients by increasing the timespan. 

https://developer.cisco.com/meraki/api-v1/#!get-network-clients

If the problem persists, more detailed information would be helpful.  

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.