Posted on 01-30-2017 12:13 PM
Hey everyone!
I was wondering if there was a way using the JAMF API to search for a specific application and version number from the API.
Basically the same type of search as
From the JSS Click Computer --> Search --> Applications: Application name + Version?
Is that possible and exposed from the API?
Example would be, there was a version of Microsoft Remote Desktop Client that had a pretty critical security update. I would like to search from the API to see how much of my laptop fleet is vulnerable.
Thanks
Posted on 01-30-2017 12:25 PM
The only way I know of to do this with the API would be to save an advanced search using the same criteria you mentioned, and then accessing that search via the API. You can't, to my knowledge, build a search on the fly with the API and retrieve results. It is possible to build an advanced search but it would be creating a new one that would show up in the JSS UI. Given that, might as well save it as a search and then just call it up in the API.
I should mention, although some will frown on it, using a Smart Group is another option, since it would pull all the same Macs into the result (minus anything not managed) The upside is, accessing a list of computer names from a Smart Group is typically much faster via the API as opposed to a saved search, which ends up building the results only at the time the search is accessed. The downside is the extra overhead incurred by having yet another Smart Group constantly calculating the group membership. So, your call on which to use.