POST
/
v1
/
search
/
user

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-site-context
string
required

The x-site-context header is a JSON object that contains information about the source you wish to pull from. The mandatory account is the 24 character identifier found in Copilot. The channel (Sales channel ID), stage (environment name), and date attributes can be used to further narrow the scope of your data source.

Body

application/json
searchFields
any[]
required

Can be a string or an array with any and all fields you want to search on.

type
enum<string>
required

The type of the search. Can be Text or Number.

Available options:
text,
number
searchValue
string
required

The search term. For text-based search it has to be a string. For number-based search it has to be an array with two items specifying the range in which you want to search. Eg.: [5, 10] will serach form records between 5 and 10.

criteria
enum<string>

Only needed for text-based searches. Specifies the criteria in which to look for text.

Available options:
BEGINS_WITH,
CONTAINS,
ENDS_WITH
scoreThreshold
number

This number specifies the certainty of the results returned. The higher the number the more accurate the return. It goes from 0 to 5. Default is 0.

offset
number

Records to skip

limit
number

Number of records to return

Response

200 - application/json
query
object
data
object[]