Response envelope

Attribute Type Description
items Array[SingleResponse] Multiple SingleResponse objects (one for each batched query sent in request)

SingleResponse

Attribute Type Description
successful Boolean Indicator whether request execution was successful
items Array[ResponseItem] Collection of entities returned by query
meta ResponseMeta Response metadata, e.g. pagination information, type, item counts, aggregation results, etc.

ResponseItem

Attribute Type Description
data Object Single entity (deal, lead or contact) returned by query. It contains only attributes explicitly requested in projection
meta ResponseItemMeta Object metadata, currently only contains object type

ResponseMeta

Attribute Type Description
type enum Always equal to collection
count Integer Number of items returned in the response
total_count Total number of items matched by the query
links PaginationCursors Pagination cursors
suggestions SuggestionsResponse Suggestions results for requested attributes
aggregations AggregationsResponse Aggregations results for requested attributes

ResponseItemMeta

Attribute Type Description
type String Type of the record

PaginationCursors

Attribute Type Description
prev_page String Cursor for the previous page (if exists)
self String Cursor for the current page
next_page String Cursor for the next page (if exists)

SuggestionsResponse

Attribute Type Description
<name_of_the_attribute> Array[AnyType] Suggestions for attribute with given name

AggregationsResponse

Attribute Type Description
<name_of_the_attribute> AggregationsResponseItem Aggregation result for attribute with given name

AggregationsResponseItem

Attribute Type Description
min AnyType Minimum value of the attribute
max AnyType Maximum value of the attribute
sum Number Sum of all the values of the attribute
avg Number Average value of the attribute
count Number Count of non-null values of the attribute
terms Array[TermResult] Top N values, ordered by document count (N defaults to 10)

TermResult

Attribute Type Description
term AnyType A term
count Number Number of documents containing term