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 and Stores containers.
It allows you to define new fields by placing them in the publicMeta
of a container or an object within a given container,
and then querying the PrivMX Endpoint Client (using existing listing methods) for elements containing these previously defined fields.
Sample code on this page is based on the initial assumptions.
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.
Creating Thread with a Custom Field
List Threads with Custom Queries
Custom Queries
Query that matches threads where publicMeta contains a field with the specified key and value:
Query that matches threads where publicMeta contains both values - one of them must meet a condition (value > 10):
Query that matches threads where publicMeta contains at least one of the given values:
List Threads with Custom Queries
You can find more query options in PrivMX Bridge API.
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 Kotlin v2.3