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

System Manager API Device Scope By Tag

SOLVED
Highlighted
Here to help

System Manager API Device Scope By Tag

Based on the documentation here, you can query devices by tag scopes but either it doesn't specify or I am misreading how to specify the scope.

 

The field description says

 

Specify a scope (one of all, none, withAny, withAll, withoutAny, or withoutAll) and a set of tags as comma separated values.

 

so it should be something like scope=withAny, but then what? Where do you list the tags to query?

 

Thank you in advance for any help on this.

WP

1 ACCEPTED SOLUTION

Accepted Solutions
Meraki Employee

Re: System Manager API Device Scope By Tag

Hey WP

 

You can include the tags after the scope descriptor, separated by a comma.

 

So, for example, if you wanted to return all devices with any of the tags "engineering" and "hq", you'd do:

 

scope=withAny,engineering,hq

 

For any devices without any of the tags "compromised", you would do:

 

scope=withoutAny,compromised

 

etc.

 

Hope this helps!

2 REPLIES 2
Meraki Employee

Re: System Manager API Device Scope By Tag

Hey WP

 

You can include the tags after the scope descriptor, separated by a comma.

 

So, for example, if you wanted to return all devices with any of the tags "engineering" and "hq", you'd do:

 

scope=withAny,engineering,hq

 

For any devices without any of the tags "compromised", you would do:

 

scope=withoutAny,compromised

 

etc.

 

Hope this helps!

Here to help

Re: System Manager API Device Scope By Tag

I'm a little embarrassed I didn't think of that. I tried a colon, semicolon, and space (%20). It didn't occur to me to use a comma.

 

Thanks for your help.

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.
Labels