Generate a search request based on a natural language query

post/assistedSearches

Generates a new request body for /searches or /paths from the given natural language query. Call /searches or /paths with the generated request to perform the search.

Request Samples

Response Samples

1{
2 "types": [
3 "report",
4 "person",
5 "vehicle",
6 "address"
7 ],
8 "query": "Show me all vehicles reported stolen in the last month",
9 "visualizationType": "summary",
10 "objectSearchRequest": {
11 "types": [
12 "vehicle"
13 ],
14 "query": {
15 "type": "text",
16 "text": "+_type:vehicle +incident:theft +last_updated_at_dttm:[2025-03-01 TO 2025-03-31]",
17 "language": "lucene",
18 "modes": [
19 "standard"
20 ]
21 },
22 "visualizations": {
23 "facets": {
24 "type": "facets",
25 "mode": "filter"
26 },
27 "selection": {
28 "type": "facets",
29 "mode": "selection"
30 },
31 "summary": {
32 "type": "summary",
33 "start": 1,
34 "limit": 50,
35 "order": {
36 "type": "score",
37 "direction": "descending"
38 }
39 }
40 }
41 }
42}

Request Body

The request to /assistedSearches when generating a search request based on a natural language query.

NameTypeRequiredDescription
version
integer
false

The representation version (1).

types
array [string]
false

The optional list of type names for the object types to be searched. If missing, all types are searched.

query
string
false

The natural language query that Generative AI will convert to one or more Lucene text queries.

visualizationType
string
false

The optional type of visualization to use in the generated search request.

Allowed values:
maprelationshipsummarytable

Responses

StatusMeaningDescription
200OK

The request succeeded.

Schema
400Bad Request

The request is malformed or contains invalid parameter values.

Schema