Search documentation
karat

+

K

User Documentation ↗

Search objects by federated source

POST/api/gotham/v1/federatedSources/{federatedSource}/namespaces/{namespace}/objects/search
Warning

This endpoint is in preview and may be modified or removed at any time. To use this endpoint, add preview=true to the request query parameters.

Search for objects in the specified federated source. The request body is used to filter objects based on the specified query. The supported queries depend on what is supported by the federated source. Returns the full object.

Path parameters

federatedSource
string

The name of the federated source to search in.

namespace
string

The namespace of the federated source to search in.

Query parameters

preview
boolean
optional

Represents a boolean value that restricts an endpoint to preview mode when set to true.

Request body

SearchFederatedSourceObjectsRequest
object

Search request to issue against a federated federated source for finding and returning objects. query is required, and represents the query to execute when searching for objects. The exact types of queries allowed depends on the federated source.

pageSize and pageToken are optional and are used for pagination of large result sets; see the Paging instructions for more information.

If not specified, pageSize defaults to a page size of 100 results; 100 is also the maximum allowed page size.

Specifying an invalid page size results in an InvalidPageSize general error.

Hide child attributes

Hide child attributes

query
union
Show child attributes

Show child attributes

not
object
optional

Returns objects where the query is not satisfied.

Show child attributes

Show child attributes

value
union
Show child attributes

Show child attributes

not
object
optional

Returns objects where the query is not satisfied.

Show child attributes

Show child attributes

value
union
or
object
optional

Returns objects where at least 1 query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
and
object
optional

Returns objects where every query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
term
object
optional

Returns objects where the specified field matches the value. The exact kind of matching depends on the data source.

Show child attributes

Show child attributes

field
string
value
any

Represents the value of a property. The following table provides expected representations of scalar data types:

TypeJSON encodingExample
DateISO 8601 extended local date string"2021-05-01"
Decimalstring"2.718281828"
Doublenumber3.14159265
Integernumber238940
Longstring"58319870951433"
Stringstring"Call me Ishmael"
TimestampISO 8601 extended offset date-time string in UTC zone"2021-01-04T05:00:00Z"
or
object
optional

Returns objects where at least 1 query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
Show child attributes

Show child attributes

not
object
optional

Returns objects where the query is not satisfied.

Show child attributes

Show child attributes

value
union
or
object
optional

Returns objects where at least 1 query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
and
object
optional

Returns objects where every query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
term
object
optional

Returns objects where the specified field matches the value. The exact kind of matching depends on the data source.

Show child attributes

Show child attributes

field
string
value
any

Represents the value of a property. The following table provides expected representations of scalar data types:

TypeJSON encodingExample
DateISO 8601 extended local date string"2021-05-01"
Decimalstring"2.718281828"
Doublenumber3.14159265
Integernumber238940
Longstring"58319870951433"
Stringstring"Call me Ishmael"
TimestampISO 8601 extended offset date-time string in UTC zone"2021-01-04T05:00:00Z"
and
object
optional

Returns objects where every query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
Show child attributes

Show child attributes

not
object
optional

Returns objects where the query is not satisfied.

Show child attributes

Show child attributes

value
union
or
object
optional

Returns objects where at least 1 query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
and
object
optional

Returns objects where every query is satisfied.

Show child attributes

Show child attributes

value
list<FederatedSearchJsonQuery>
optional
Show child attributes

Show child attributes

FederatedSearchJsonQuery
union
term
object
optional

Returns objects where the specified field matches the value. The exact kind of matching depends on the data source.

Show child attributes

Show child attributes

field
string
value
any

Represents the value of a property. The following table provides expected representations of scalar data types:

TypeJSON encodingExample
DateISO 8601 extended local date string"2021-05-01"
Decimalstring"2.718281828"
Doublenumber3.14159265
Integernumber238940
Longstring"58319870951433"
Stringstring"Call me Ishmael"
TimestampISO 8601 extended offset date-time string in UTC zone"2021-01-04T05:00:00Z"
term
object
optional

Returns objects where the specified field matches the value. The exact kind of matching depends on the data source.

Show child attributes

Show child attributes

field
string
value
any

Represents the value of a property. The following table provides expected representations of scalar data types:

TypeJSON encodingExample
DateISO 8601 extended local date string"2021-05-01"
Decimalstring"2.718281828"
Doublenumber3.14159265
Integernumber238940
Longstring"58319870951433"
Stringstring"Call me Ishmael"
TimestampISO 8601 extended offset date-time string in UTC zone"2021-01-04T05:00:00Z"
pageSize
integer
optional

The page size to use for the endpoint.

pageToken
string
optional

The page token indicates where to start paging. This should be omitted from the first page's request. To fetch the next page, clients should take the value from the nextPageToken field of the previous response and populate the next request's pageToken field with it.

Response body

SearchObjectsResponse
object

A list of the objects that match the search query.

Hide child attributes

Hide child attributes

data
list<GothamOntologyObject>
optional
Show child attributes

Show child attributes

GothamOntologyObject
object

Represents an object in the Object Store.

Show child attributes

Show child attributes

primaryKey
string

The primary key/unique identifier of an object, useful for interacting with Gotham APIs to load and mutate objects.

title
string
optional

The title of an object, which represents a display-friendly String of what the object represents.

objectType
string

The name of the object in the API - also called the Object Type URI.

properties
map<PropertyApiName, array>
optional

A map of the property values of the object.

Show child attributes

Show child attributes

PropertyApiName
string

The name of the property in the API - also called the Property Type URI.

array
list<PropertyValue>
Show child attributes

Show child attributes

PropertyValue
any

Represents the value of a property. The following table provides expected representations of scalar data types:

TypeJSON encodingExample
DateISO 8601 extended local date string"2021-05-01"
Decimalstring"2.718281828"
Doublenumber3.14159265
Integernumber238940
Longstring"58319870951433"
Stringstring"Call me Ishmael"
TimestampISO 8601 extended offset date-time string in UTC zone"2021-01-04T05:00:00Z"
intrinsicCoordinates
object
optional
Show child attributes

Show child attributes

longitude
number
latitude
number
elevation
number
optional
timeInterval
object
optional

Represents a time interval by its start and end datetime. TimeInterval is generally used when an Object has a meaningful start and/or end datetime, such as an event. For example, a Meeting might have start and end datetimes corresponding to when the meeting began and ended.

Show child attributes

Show child attributes

timeStart
string
optional
timeEnd
string
optional
nextPageToken
string
optional

The page token indicates where to start paging. This should be omitted from the first page's request. To fetch the next page, clients should take the value from the nextPageToken field of the previous response and populate the next request's pageToken field with it.

Examples

Request

Copied!
1 2 3 4 5 curl -X POST \ -H "Content-type: application/json" \ -H "Authorization: Bearer $TOKEN" \ "https://$HOSTNAME/api/gotham/v1/federatedSources/My Federated Source/namespaces/My Federated Source namespace/objects/search?preview=true" \ -d '{"query":{"type":"and","value":[{"type":"term","field":"com.palantir.property.name:FIRST_NAME","value":"John"},{"type":"term","field":"com.palantir.property.age","value":24}]}}'

Response

Copied!
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 { "data": [ { "primaryKey": "ri.gotham.111111-0.object-internal.111111", "objectType": "com.palantir.object.person", "properties": { "com.palantir.property.name": [ { "FIRST_NAME": "John", "LAST_NAME": "Smith" } ], "com.palantir.property.age": [ 37 ] } } ] }