cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1521
Views
9
Helpful
10
Replies
Highlighted
Beginner

CMX 10 notifications API question

Hi,

I am integrating CMX API into our system and I need to get information about all location changes.

Right now I am using the 'LocationUpdate' notification type and have an initial implementation of the data receiver/processor.

The problem is that CMX sends us individual location items (one per CMAC) at a very high rate (hundreds of requests per second) and

this doesn't fit our architecture and in general we don't need to have updates that often.

It would be much easier for us to get location updates in batches every 1-2 minutes (this is how it works for other devices we already integrated, like Aruba and Meraki).

Live API documentation doesn't hint what are possible configuration parameters for notifications (especially for those accepting a json object, like "rules").

So the question is whether it is possible to configure LocationUpdate notification to send notifications in batches (not individual location items) and less frequently?
Or maybe I need to use some other notification type?

And a general question - maybe there is at least some draft of the API guide or any other more detailed information already available?

10 REPLIES 10
Highlighted
Frequent Contributor

Re: CMX 10 notifications API question

Hi Boris,  Let me research how to do this.  I'll forward to engineering for advise, also.  Matt

Highlighted
Beginner

Re: CMX 10 notifications API question

Matt, thanks for reply, please let me know if engineering team can advice something.

Highlighted
Beginner

Re: CMX 10 notifications API question

Hi, Boris.

I think that in CMXv10 movement notification out to JSON API directly from WLC (NMSP) events through internal Redis service without time aggregation.

Only distance aggregation (by feet) is present. You may use "Movement" trigger instead "Location Update". In this case utilization will decrease.

We are using time aggregation in our application server.

Highlighted
Beginner

Re: CMX 10 notifications API question

Dmitry, thank you very much for the hint, I'll check the 'Movement' trigger.

I was also thinking about implementing a data buffer with time aggregation for the location update, but that's an additional complexity I would like to avoid if possible.

Highlighted
Beginner

Re: CMX 10 notifications API question

Hi, Boris.

You are right about API documentation. The information about new CMXv10 API is not enough. Therefore we are using so far static triggers from GUI.

About data aggregation. I think that manual events aggregation in current release is needed for your application. We are using it in our project.

Or the second way is periodical request data keys directly from CMX Redis service. There are all keys that you need (if you know MAC). From CMX CLI command to connect:

redis-cli -p 6379     (or 6385)

For example JSON data about interesting MAC is availible by request:

get "mob_loc$d8:45:a3:e2:7d:81"

All keys are availible by request:

keys mob_loc$*

Highlighted
Beginner

Re: CMX 10 notifications API question

Dmitry, thanks a lot for the information.

I checked LocationUpdate and Movement triggers and came to the same conclusion - to develop a mini-service to receive the data and do the aggregation before we actually process the data.

Highlighted
Frequent Contributor

Re: CMX 10 notifications API question

Hi Boris,

Additional advice from engineering folk.

Matt

Hi Matt,

There is no way to throttle the Northbound notifications as such. You get notified as soon as the event is processed in CMX, we can’t send it in batches. If you go for Movement Notification trigger, you can try to limit the number of notifications by having a higher ‘distance’ value in the trigger subscription.

Regards,

Prasad.


From: "Matthew Farrell -X (matfarre - INSIGHT GLOBAL INC at Cisco)" <matfarre@cisco.com>

Date: Thursday, December 17, 2015 at 11:01 AM

To: "cs-location(mailer list)" <cs-location@cisco.com>

Subject: CMX 10 notifications API question

Hello Experts,

Checking to see if engineering team can provide additional advice regarding using ‘LocationUpdate’ versus 'Movement’ notification type, and limiting the frequency of updates.

Thanks,

Matt

Highlighted
Beginner

Re: CMX 10 notifications API question

Hi Matt,

Thank you for the information and for the help, I will try Movement trigger.

And regarding the API documentation - do you know if some more detailed docs are available already? Maybe some draft version?

Highlighted
Frequent Contributor

Re: CMX 10 notifications API question

Boris,

I do not know of a new release of CMX API documentation for version 10, but I will ask again.  Here is the reply.  The CMX Engineering team would like to modify existing content and add new ones to DevNet site.  However, they have never mentioned a if/when a Cisco MSE API Guide new release for 10.0 would be available.

Matt

Subject: Re: Cisco MSE API Guide, Release 10.0

Hi CMX Engineering,

I believe we need more documentation than the Live apidocs provide.  This is the single biggest issue we have with CMX questions on the DevNet site.

I was added to the email thread, see attached, by Paul Zimmerman my manager for DevNet documentation.  I look forward to discussing the revamp of CMX content with you.

Thanks,

Matt


Subject: Re: Cisco MSE API Guide, Release 10.0

https://<CMX10IPADDR>/apidocs


Subject: Cisco MSE API Guide, Release 10.0

Hi Experts,

Any information on a Cisco MSE API Guide, Release 10.0 document, maybe a draft version available. 

There are many requests for it, since the Live apidocs lacks detailed information regarding parameters, options, examples.

Thanks,

Matt

Highlighted
Beginner

Re: CMX 10 notifications API question

Matt, you absolutely right here "the Live apidocs lacks detailed information regarding parameters, options, examples".

Even if we put aside usage examples and a guide / tutorial, current api docs are just not enough to use the API.

Because we can't just guess what values can be passed to some of the parameters.

For example, for LocationUpdate notification the "rules" parameter can look like this:

"rules": [ {

   "conditions": [ {

         "condition": "locationupdate.deviceType == client"

   } ]

} ]

Explanation for this parameter in apidocs states: "List of rules.".

It is a json object and with live apidocs it is just impossible to know what should be inside.

I didn't review all the API methods and maybe most of them are self-explanatory, but definitely not all of them.

CreatePlease to create content
Content for Community-Ad
Cisco Community April 2020 Spotlight Award Winners