HCP metadata query API

Content Platform Tenant Management Help

File Size
4269 KB
Part Number

The HCP metadata query API lets you search HCP for objects that meet specified criteria. The API supports two types of queries:

  • Object-based queries search for objects based on object metadata. This includes both system metadata and the content of custom metadata and ACLs. The query criteria can also include the object location (that is, the namespace and/or directory that contains the object). These queries use a robust query language that lets you combine search criteria in multiple ways.

    Object-based queries search only for objects that currently exist in the repository. For objects with multiple versions, object-based queries return only the current version.

  • Operation-based queries search not only for objects currently in the repository but also for information about objects that have been deleted by a user or application or deleted through disposition, purged or pruned. For namespaces that support versioning, operation-based queries can return both current and old version of objects.

    Criteria for operation-based queries can include object status (for example, created or deleted), change time, index setting, and location.

The metadata query API returns object metadata only, not object data. The metadata is returned either in XML format, with each object represented by a separate element, or in JSON format, with each object represented by a separate name/value pair. For queries that return large numbers of objects, you can use paged requests.