Homepage

Selecting Fields Available for Search

Last edit: Jan 25, 2024

Warning

This article promotes customizations, listings and people GraphQL queries, which are deprecated due to the limited configuration option. To leverage the power of ElasticSearch, we recommend using JSON Documents, which allows you to define your own ElasticSearch mapping and have full control on what gets stored in the ElasticSearch.

Some use cases require you to select fields available for search. For example, you want to give your users the ability to search through users but only using their first_name.

Profile fields

query get_owners {
  people(query: { keyword: "John", fields: [{ name: "first_name" }] }) {
    results {
      first_name
    }
  }
}

Returns users whose first_name exactly matches John.

Questions?

We are always happy to help with any questions you may have.

contact us