View Source Meilisearch.Settings.DistinctAttributes (meilisearch_ex v1.1.2)
see documentation
Link to this section Summary
Functions
Get distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
Reset distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
Update distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
Link to this section Functions
@spec get(Tesla.Client.t(), String.t()) :: {:ok, String.t()} | {:error, Meilisearch.Client.error()}
Get distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
examples
Examples
iex> client = Meilisearch.Client.new(endpoint: "http://localhost:7700", key: "master_key_test")
iex> Meilisearch.Settings.DistinctAttributes.get(client, "movies")
{:ok, "skuid"}
@spec reset(Tesla.Client.t(), String.t()) :: {:ok, Meilisearch.SummarizedTask.t()} | {:error, Meilisearch.Client.error()}
Reset distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
examples
Examples
iex> client = Meilisearch.Client.new(endpoint: "http://localhost:7700", key: "master_key_test")
iex> Meilisearch.Settings.DistinctAttributes.reset(client, "movies")
{:ok, %{
taskUid: 0,
indexUid: "movies",
status: :enqueued,
type: :settingsUpdate,
enqueuedAt: ~U[2021-08-12 10:00:00]
}}
@spec update(Tesla.Client.t(), String.t(), String.t()) :: {:ok, Meilisearch.SummarizedTask.t()} | {:error, Meilisearch.Client.error()}
Update distinct attribute settings of an Index of your Meilisearch instance. Meilisearch documentation
examples
Examples
iex> client = Meilisearch.Client.new(endpoint: "http://localhost:7700", key: "master_key_test")
iex> Meilisearch.Settings.DistinctAttributes.update(client, "movies", "skuid")
{:ok, %{
taskUid: 0,
indexUid: "movies",
status: :enqueued,
type: :settingsUpdate,
enqueuedAt: ~U[2021-08-12 10:00:00]
}}