BigFix API Query to pull Identifying number - windows help

Trying all kinds of queries, but none seem to work.

https://<server_URL>:52311/api/query?relevance=(identifying+number+-+Windows+of+it)+of+bes+properties

All come back with:

The operator “identifying number” is not defined.

The operator "identifying number" is not defined.

thoughts?

Before you try to URL-encode your query and run it through the API, test it out, using the Web Reports QNA page.

https://your-webreports-server:8083/webreports?page=QNA

There is a property with that name, if you’ve activated the right Analysis from “BES Inventory and License”

Q: names of bes properties whose (name of it as lowercase contains "identifying number")
A: Identifying Number - Windows

But, “identifying number” is not a property of a “bes property”. You can see what things are properties of a BES Property using a special class of relevance called “introspectors”, or see what you can query by browsing the Inspectors at https://developer.bigfix.com

Using the Introspector, I can see that a ‘bes property’ type has a lot of properties. I’m only going to show a few of them here:

q: properties of type "bes property"
A: name of <bes property>: string
A: source analysis of <bes property>: bes fixlet
A: results of <bes property>: bes property result
A: result from <bes computer> of <bes property>: bes property result

I think it’s likely you want the results of the property, right? There is a ‘results’ property from a bes property, which returns type “bes property result”, so let’s get a description for the ‘bes property result’ type:

q: properties of type "bes property result"
A: computer of <bes property result>: bes computer
A: property of <bes property result>: bes property
A: error message of <bes property result>: string
A: plural flag of <bes property result>: boolean
A: error flag of <bes property result>: boolean
A: value count of <bes property result>: integer
A: values of <bes property result>: string

From a ‘bes property result’, we can get several properties, the most interesting probably being the ‘value’ of the result, and the ‘bes computer’ that reported that value. I could do the same introspection to see what properties a ‘bes computer’ has, but I already know the ones I want are probably the BES Computer ID and the Computer Name.

So to summarize, what I think we want, is for each result of the property, retrieve the name of the computer and the value that computer reported:

q: (name of computer of it | "Not Reported", values of it) of results of bes properties whose (name of it = "Identifying Number - Windows")
A: BES-ROOT, 4269-0282-1426-4548-5290-6320-54
A: ENDPOINT-1, 1602-7358-4526-4175-3673-3448-08
A: BFC, 9103-0388-0424-7213-8687-7743-57
A: WIN2016-1581-58, 1581-5853-3390-5672-0341-7262-92
A: WEBUI, 7574-3630-5177-9989-4144-4766-06
A: SCCM, 0897-9378-5322-7139-8143-0073-47
A: OSD, 4330-9052-6529-5889-2640-3271-55
A: BFI, 3976-8002-5156-3735-7557-7898-31
A: DC, 0122-1939-8056-5006-8806-5266-60

So, once you’ve tested a working query, you (or your script tool) can URL-encode that and send it through the API.

thank you for the time and explanation.

If you are trying to get info for Windows AutoPilot, you can do that directly in client relevance. See these examples:

You may have to break up the result to get it to work correctly in an analysis.