The search history API returns a list of a users most recent searches performed by a given user.

📘

Prerequisites

Before obtaining meaningful data from this API ensure that

  • You have you API apikey. Contact us to find out how to get access.
  • To personalise responses it is vital to capture an end user identifier as part of behaviour capture. Without such user ids, the api will not be able to surface a specific users search history.

Example Call

Querying the top search API is as simple as making a call to the endpoint and including your apikey and a valid end user id.

Details of the request and response objects are given in Request/Response

{
  "apikey": <your api key>,
  "max_results": 10,
  "customer_enduser_id": <end user id>
}
curl -X 'POST' \
  'https://personafinai.azurewebsites.net/v2/personalized/search/history' \
  -H 'accept: */*' \
  -H 'Content-Type: application/json' \
  -d '

{
  "apikey": <your api key>,
  "max_results": 10,
  "customer_enduser_id": <end user id>
}'

The API will output a list of the most recent searches performed by a user, as defined by the Response object below

Request/Response

Request Object

The API request expects the following endpoint url and body parameters

POST https://personafinai.azurewebsites.net/v2/personalized/search/history

FieldDescription
apikey
string
Authentication key to use to retrieve data
maxresults
_int
The number of results to return
customerenduser_id
_string
Value used to identify user on target platform

Response Object

The API will respond with an object containing the following

FieldDescription
behaviourevent_guid
_string
The internal guid used to identify a specific search performed
entityguid
_string
If the search is linked to an instrument or financial entity, the entity_guid corresponds to an internal value assigned to that entity.
This may be null depending on permissions enabled for your api
entitycustomer_id
_string
If the search is linked to an instrument of financial entity, the entity_customer_id corresponds to the identifying symbol or instrument associated with that entity on the platform on which the search was performed.
unixlast_Searched
_int
Unix timestamp of when the search was performed.
searcheddatetime
_datetime
The datetime when the search was performed
eventtype
_string
The type of event associated with the search. Typically "search_selected".
behaviourevent_meta
_object
A list of JSON objects outlining meta data captured along with the search event. This contains key value pairs corresponding the type of meta data.
Typically this will hold
{
"key": "term",
"value":
}

Notes

Language
Click Try It! to start a request and see the response here!