Types of Public Content API fields

There are different types of fields you can use or encounter when using the Public Content API.

Root fields
The following are queryable root fields. All field values above should be supplied enclosed in double quotation marks.
Name of root fieldRemarks
author
clientId
contentseparated by language; strict property has a special meaning (see below)
createdDatestrict property not supported
dynamicDate
dynamicDouble
dynamicLong
dynamicText
itemType
languageField
locale
location
majorVersion
metadataField
minorVersion
modifiedDatestrict property not supported
namespace
publicationId
publicationTitle
rawLanguageTitleseparated by language; strict property has a special meaning (see below)
schemaId
url
Finding an exact match or a fuzzy match for a root field depends on the type of content in the field:
  • Root fields that contain strings can be queried for their exact value only, by using the strict property set to true, or for their exact value and similar values, by setting strict to false.
  • Root fields that contain timestamps must have strict set to false. You can make the query for this type field field more or less fuzzy by supplying a more specific or less specific timestamp. For example, the query value 2020-08-25 finds any timestamp on that day, while 2020-08-25T14 finds only timestamps between 14:00:00 and 14:59:59.
Metadata fields
To query metadata fields, use the metadataField field, specifying the metadata field name (keys array), the value you're looking for (value) and the data type of the field (type).
The type field must be one of the following values:
  • DATE
  • DOUBLE
  • LONG
  • TEXT
  • ANY
If this field contains further embedded fields, add the embedded field you want to query as an additional entry in the keys array. For example, a keys value of ["address","houseNumber"] refers to the metadata field houseNumber that is part of the metadata field address.
The strict property works the same as for root fields.
Language-specific fields
To search for content in a specific language, use languageField with the subfields key (the field you want to search, say content), value (the text you want to search for), and language (the language in which you want to search).
The value of the strict property affects how GraphQL returns the search results for a multi-string search term:
  • If strict is set to true, exact matches of the multi-string search term are returned first; matches containing one or more of strings, but not in the order given, are returned next. For example, a search for "interest rate" will first return all objects containing that exact phrase, and will then return all objects containing "interest" or "rate" or both.
  • If strict is set to false, results are presented in a predefined order determined by OpenSearch.
Non-searchable fields
Any fields that were configured as non-indexable in Content Manager are in the OpenSearch database, but are not searchable. The only way to retrieve the content of such fields is by including them in the search results of a search for a different field.
Fields that can be retrieved as a searchResult
The following fields can be retrieved as a search result:
Field nameData typeRemarks
authorString
binaryAuthorStringExtracted by Apache Tika plugin for OpenSearch
binaryContentLengthLongExtracted by Apache Tika plugin for OpenSearch
binaryContentTypeStringExtracted by Apache Tika plugin for OpenSearch
binaryCreatedDateStringExtracted by Apache Tika plugin for OpenSearch
binaryFileNameStringExtracted by Apache Tika plugin for OpenSearch
binaryLanguageStringExtracted by Apache Tika plugin for OpenSearch
binaryTitleStringExtracted by Apache Tika plugin for OpenSearch
conceptSchemesString
createdDateString
fieldsMapContains dynamic and non-dynamic metadata
highlightedMapRetrievable only if highlighting was enabled in the search request
idString
itemTypeString
localeString
locationString
mainContentFieldString
majorVersionString
minorVersionString
modifiedDateString
namespaceString
publicationIdInt
publicationTitleString
rawContentString
rawLanguageTitleString
schemaIdString
scoreFloat
urlString