Search API



A question was asked how to retrieve results for all candidates that do not have a blank or null background check completed date. This example displays retrieving results with a filter of "as of today"

Call Type: POST
URL: https://api.icims.com/customers/6271/search/people
Payload:
{"filters":[{"name":"person.collectionfield3256date","secondaryValue":["{DATE:END}"],"value":[],"operator":"="}],"operator":"&"}

Results (truncated):
{
"searchResults": [
{
"self": "https://api.icims.com/customers/6271/people/22",
"id": 22
},
{
"self": "https://api.icims.com/customers/6271/people/148",
"id": 148
},
{
"self": "https://api.icims.com/customers/6271/people/200",
"id": 200
},
{
"self": "https://api.icims.com/customers/6271/people/201",
"id": 201
},
{
"self": "https://api.icims.com/customers/6271/people/204",
"id": 204
},
{
"self": "https://api.icims.com/customers/6271/people/205",
"id": 205
},

From here you can run a GET on each person to retrieve their details.

- iCIMS UNIFI

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

What is the API field name/number for the “bgcorderstatus” field?

When querying the person entity, I’ve tried using “field3256”, “bgccompleteddate”, and “collectionfield3256”, but neither requested field returns any data, even when I use the code/filter provided in the forum example (which returns > 1000 results). I’m currently able to return BGC Order Status and BGC Screening Type, but not BGC Completed Date.

Also, I was told the API field name/number was “field41990” for rcf2039 (Terminated last work date), but I’m unable to return any data for that field when it’s included in my query column list. Is 41990 the correct field number?

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

Also, your filter above for my original question doesn't seem to work. It returns everyone in our system including people without any background check data and those with null/empty background check dates. Also, shouldn't the "=" be a "!=", since the original question was background check completed date is "not blank/empty"?

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

Hello Jack,
It sounds like you are looking for custom field settings and the UNIFI Team would not know that field id because customers can have up to 300 custom fields within their platform, created as various types. Customer specific field ID's, API or FlatFile, can be given by your account manager, technical account manager or if you are working with an integration team resource, they will give you that variable. Your api call for a custom field would begin with "field" and then a numerical value.

The api id for the order status is bgcorderstatus. Here is a link to the standard fields for a person profile, https://developer.icims.com/Data-Models/Person-Profile/Person .

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

Yes. I know it's a custom field. I was told to reply here to forum when I sent an email.

I get the following errors when I try various ways to query on "bgcorderstatus" field to search for people:

X-Error: 5:The following filter is either not valid or hidden: bgcorderstatus
X-Error: 5:The following filter is either not valid or hidden: person.bgcorderstatus
X-Error: 5:The following filter is either not valid or hidden: person.bgcorderstatus.value
X-Error: 5:The following filter is either not valid or hidden: person.bgcorderstatus.text
X-Error: 5:The following filter is either not valid or hidden: person.bgcresults.bgcorderstatus
X-Error: 5:The following filter is either not valid or hidden: person.bgcresults.bgcorderstatus.text
X-Error: 5:The following filter is either not valid or hidden: person.bgcresults.bgcorderstatus.value

The API documentation for bgccompleteddate says "person.bgcresults.bgccompleteddate" (on link provided above), but you provided example API code showing that it's actually "person.collectionfield3256date", so I assume the "bgcorderstatus" also has a different name with "collectionfield" instead of what the Data Model states.

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

Hi Jim,
We do not have a "not blank" type of filter however you can place a specific date range. In line with the URL above, here is an example payload:
{"filters":[{"name":"person.collectionfield3231date","secondaryValue":["2017-07-20 05:59 AM"],"value":["2017-07-04 06:00 AM"],"operator":"="}],"operator":"&"}

Result:
{
"searchResults": [
{
"self": "https://api.icims.com/customers/6271/people/1175",
"id": 1175
},
{
"self": "https://api.icims.com/customers/6271/people/1216",
"id": 1216
},
{
"self": "https://api.icims.com/customers/6271/people/1732",
"id": 1732
},
{
"self": "https://api.icims.com/customers/6271/people/1820",
"id": 1820
},
{
"self": "https://api.icims.com/customers/6271/people/1842",
"id": 1842
},
{
"self": "https://api.icims.com/customers/6271/people/1844",
"id": 1844
},
{
"self": "https://api.icims.com/customers/6271/people/1862",
"id": 1862
}

Submitted by iCIMSUNIFIL on July 19, 2017 Permalink

Here is a payload example for the orders status:
{"filters":[{"name":"person.collectionfield3229listnode","value":["D37002026004","D37002026006","D37002026005","D37002026003","D37002026002","D37002026001"],"operator":"="}],"operator":"&"}

Result (truncated):
{
"searchResults": [
{
"self": "https://api.icims.com/customers/6271/people/22",
"id": 22
},
{
"self": "https://api.icims.com/customers/6271/people/24",
"id": 24
},
{
"self": "https://api.icims.com/customers/6271/people/25",
"id": 25
},
{
"self": "https://api.icims.com/customers/6271/people/40",
"id": 40
},
{
"self": "https://api.icims.com/customers/6271/people/103",
"id": 103
},
{
"self": "https://api.icims.com/customers/6271/people/106",
"id": 106
},

Regarding custom fields, that information is on a customer basis and should be supplied, not by the UNIFI Team, but your customer account representative.

Submitted by iCIMSUNIFIL on July 20, 2017 Permalink

Thanks. Any advice why this filter doesn't work? It finds persons with bgc order status of "completed", but the date part also returns nulls.

{"filters":
[
{"name":"person.collectionfield3229listnode","operator":"=","value":["D37002026001"]},
{"name":"person.collectionfield3256date","operator":"=","value":["1925-01-01"],"secondaryValue":["2017-07-21"]}
],
"operator":"&"
}

In reply to by iCIMSUNIFIL

Submitted by iCIMSUNIFIL on July 20, 2017 Permalink

Thanks. "collectionfield3229listnode" was the fieldname I was looking for and couldn't find in the Data Model doc.

Thanks,

Submitted by iCIMSUNIFIL on July 20, 2017 Permalink

We logged in your test site and created a user to replicate what you are doing. You are getting that hidden error because the custom field id is not present in your test instance. That ID parameter for the search api payload is person.customfield2039. Here's the query run:
URL: https://api.icims.com/customers/7316/search/people
Payload (to narrow the results):
{"filters":[{"name":"person.customfield2039.date","secondaryValue":["2017-07-20 04:00 AM"],"value":["2016-04-01 04:00 AM"],"operator":"="},{"name":"person.collectionfield3229listnode","value":["D37002026001"],"operator":"="},{"name":"person.collectionfield3231date","secondaryValue":["2017-07-21 03:59 AM"],"value":["2016-04-01 04:00 AM"],"operator":"="}],"operator":"&"}

Results (truncated):
{
"searchResults": [
{
"self": "https://api.icims.com/customers/7316/people/90552",
"id": 90552
},
{
"self": "https://api.icims.com/customers/7316/people/90727",
"id": 90727
},
{
"self": "https://api.icims.com/customers/7316/people/93024",
"id": 93024
},
{
"self": "https://api.icims.com/customers/7316/people/93272",
"id": 93272
},
{
"self": "https://api.icims.com/customers/7316/people/96652",
"id": 96652
},
{
"self": "https://api.icims.com/customers/7316/people/110446",
"id": 110446
},
{
"self": "https://api.icims.com/customers/7316/people/114175",
"id": 114175
},
{
"self": "https://api.icims.com/customers/7316/people/114344",
"id": 114344
},
{
"self": "https://api.icims.com/customers/7316/people/115776",
"id": 115776
},
{
"self": "https://api.icims.com/customers/7316/people/118649",
"id": 118649
},
{
"self": "https://api.icims.com/customers/7316/people/118744",
"id": 118744
},
{
"self": "https://api.icims.com/customers/7316/people/120008",
"id": 120008
},
{
"self": "https://api.icims.com/customers/7316/people/125856",
"id": 125856
},
{
"self": "https://api.icims.com/customers/7316/people/138088",
"id": 138088
},
{
"self": "https://api.icims.com/customers/7316/people/138358",
"id": 138358
},
{
"self": "https://api.icims.com/customers/7316/people/142364",
"id": 142364
}

Ran a couple of random GETs and did not see any blank screening dates.

Thanks!

Submitted by iCIMSUNIFIL on July 21, 2017 Permalink

Thanks. I wasn't using the test instance, so the field was present. Using "customfield2039" in the search filters doesn't return an error, but I still cannot see any responses/data in that field in my results even when I specifically include "customfield2039" in the column/field list request.