Skip to main content

Query Tenant Content

GET 

/tenants/:tid/q/query

Query published content versions belonging a tenant.

The following query parameters allow customizing the listing.

Sorting

Sorting Examples

?sort_by=name
&sort_descending=true

?sort_by=slug
  • Query param sort_by: the name of content query fields to sort on. Only a single sort field is supported. If omitted, contents are sorted on creation date.
  • Query param sort_descending: false for ascending sort order, true for descending sort order. Default: false (ascending)

Filtering

Filtering Examples

Examples:
?filter=tag:eq:feature%20film

?filter=tag:eq:action
&filter=created_block_time:ge:2023-01-01
  • Query param filter: a content field name separated with a comparator from the value to match. Multiple instances allowed.

Field Names:

  • tag a content tag
  • group a content group
  • unique_group.id a unique group's id
  • unique_group.type a unique group's type
  • created_block_number the number of the block in which the content version was created
  • created_block_time the version's creation time in ISO 8601 format, e.g. 2006-01-02T15:04:05.000Z07:00 or 2006-01-02

Comparators:

  • ::, :co: contains
  • :nc: not contains
  • :eq: equals
  • :ne: not equals
  • :lt: less than
  • :le: less than or equal
  • :gt: greater than
  • :ge: greater than or equal

Notes:

  • values MUST be percent-encoded.
  • metadata paths SHOULD be percent-encoded as well (even though the URI "query" string specifically allows forward slashes /)

Additional Filtering

Additional Filtering Examples

?latest_version_only=false
  • Query param latest_version_only: tag without value or bool to retrieve only the latest content version per content ID. Default: true.

Selection

Selection Examples

?select=/public

?select=/public/name
&select=/public/description
&select=/public/thumbnail

Query param select: path of metadata subtree to return. If the query parameter is specified multiple times, the results of each expression are merged. If not specified, no meta data is returned.

Removal

Removal Examples

?remove=/public/description

?select=/public
&remove=/public/description
&remove=/public/thumbnail

Query param remove: path of metadata subtree to remove from the result. May be specified multiple times.

Paging

Paging Examples

?start=20
&limit=10
  • Query param start: index of the first content object to retrieve. Leave empty to retrieve the first content.
  • Query param limit: integer specifying the number of contents to return. Default: 100.

Request

Responses

The list of contents.