Custom Fields and Queries
Using custom fields and querying them in Thread and Store Containers.
Custom fields and querying them is a functionality that works with Threads, Stores, and their respective items.
It allows you to define new fields by placing a JSON in the publicMeta
of a Container or an item within a given Container,
and then querying the PrivMX Endpoint Client (using the respective list
methods) for elements containing these previously defined fields.
For more information go to PrivMX Bridge API.
Working with Custom Fields and Queries
Below there is a simple code example of how to add a custom field to a batch of Threads, and then search for them using custom query.
Defining a Sample Custom Field
Custom Queries
Simple Query
The simple query essentially checks for equality of a single field:
Comparative Query
You can compare a field to a value using a comparative query:
Nested Values
You can access nested values in a query with the dot notation:
Compound Query
You can combine multiple queries with logical operators:
We use cookies on our website. We use them to ensure the proper functioning of the site and, if you agree, for purposes we set, such as analytics or marketing.
PrivMX Endpoint Swift v2.3