Skip to main content

Cookie control banner

Necessary Cookies
These cookies are necessary for this website to function correctly. They are set when you perform certain actions on the site, such as creating an account, logging in, changing your privacy preferences or submitting a form. You can block these cookies in your browser, but this will stop parts of the site from working properly.
Functional Cookies
These cookies allow the website to provide extra functionality and more personalised experiences. They may be set by us or by third party providers whose services we have added to our pages. If you choose not to allow these cookies, these services may not work correctly.
Analytical Cookies
These cookies record anonymous data on how visitors use our website to help us monitor how well our website works. This data includes how many people have looked at specific pages, how long visitors stay on the site, and what devices they use. We use this data to identify changes that we could make to improve your experience and make our website more efficient.
Marketing Cookies
We set some cookies so you are shown more relevant marketing content. These include cookies from third-party advertising networks to show you different adverts on their services if you have previously visited our site. If you choose not to allow these cookies, you may experience less relevant advertising on other sites.
Browse Documentation

ZenQL search – overview

Created by r.saunders, last modified by r.bromley on 13 Feb 2022

ZenQL stands for Zengenti Query Language. It provides a flexible way to search for content and other resources in Contensis. ZenQL can be passed as a HTTP GET request using a query parameter named zenql. It gives you an efficient and fluent alternative to the exisiting JSON-based search available in our APIs.

The grammar used by ZenQL is separated from specific data schemas. The operators, functions, and relative time periods of ZenQL can be used across all our APIs, apart from a few exceptions where they are not semantically applicable.

ZenQL Syntax

A query in ZenQL (also known as a “clause”) consists of a field, followed by an operator, followed by one or more values or functions and optional keywords.

  • Field – the first component of a ZenQL clause that refers to the attribute or type of information you are querying e.g. a field in an entry, or an attribute of a user.
  • Operator - the part of the clause that relates or compares a function or value with the field that precedes it.
  • Value – the part of the clause that describes the content you are querying based on the information stored in its field.
  • Keyword - a word or phrase that serves a specific purpose in defining your query, such as linking two clauses or altering the logic of a clause or operator.

Syntax examples

Searching for all entries that are of the plant content type.

sys.contentTypeId = plant 

Plant entries that have been created this week.

sys.contentTypeId = plant and sys.version.created >= startOfWeek()

Find the full list of keywords, operators, functions and field references along with additional resources here: