View Source Meilisearch.Health (meilisearch_ex v1.1.2)

Retreive Meilisearch health status. Health API

Link to this section Summary

Functions

Get a response from the /health endpoint of Meilisearch. Meilisearch documentation

Check the response from the /health endpoint of Meilisearch. Meilisearch documentation

Link to this section Types

@type t() :: %Meilisearch.Health{status: String.t()}

Link to this section Functions

@spec get(Tesla.Client.t()) :: {:ok, t()} | {:error, Meilisearch.Client.error()}

Get a response from the /health endpoint of Meilisearch. Meilisearch documentation

examples

Examples

iex> client = Meilisearch.Client.new(endpoint: "http://localhost:7700", key: "master_key_test")
iex> Meilisearch.Health.get(client)
{:ok, %{status: "available"}}
@spec healthy?(Tesla.Client.t()) :: boolean()

Check the response from the /health endpoint of Meilisearch. Meilisearch documentation

examples

Examples

iex> client = Meilisearch.Client.new(endpoint: "http://localhost:7700", key: "master_key_test")
iex> Meilisearch.Health.healthy?(client)
true