Enum meilisearch_sdk::errors::Error
source · #[non_exhaustive]pub enum Error {
Show 14 variants
Meilisearch(MeilisearchError),
MeilisearchCommunication(MeilisearchCommunicationError),
UnreachableServer,
ParseError(Error),
Timeout,
InvalidRequest,
CantUseWithoutApiKey(String),
TenantTokensInvalidApiKey,
TenantTokensExpiredSignature,
InvalidTenantToken(Error),
HttpError(Error),
Yaup(Error),
Uuid(Error),
InvalidUuid4Version,
}Expand description
An enum representing the errors that can occur.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Meilisearch(MeilisearchError)
The exhaustive list of Meilisearch errors: https://github.com/meilisearch/specifications/blob/main/text/0061-error-format-and-definitions.md
Also check out: https://github.com/meilisearch/Meilisearch/blob/main/meilisearch-error/src/lib.rs
MeilisearchCommunication(MeilisearchCommunicationError)
UnreachableServer
There is no Meilisearch server listening on the [specified host] (../client/struct.Client.html#method.new).
ParseError(Error)
The Meilisearch server returned an invalid JSON for a request.
Timeout
A timeout happened while waiting for an update to complete.
InvalidRequest
This Meilisearch SDK generated an invalid request (which was not sent).
It probably comes from an invalid API key resulting in an invalid HTTP header.
CantUseWithoutApiKey(String)
Can’t call this method without setting an api key in the client.
TenantTokensInvalidApiKey
It is not possible to generate a tenant token with a invalid api key.
Empty strings or with less than 8 characters are considered invalid.
TenantTokensExpiredSignature
It is not possible to generate an already expired tenant token.
InvalidTenantToken(Error)
When jsonwebtoken cannot generate the token successfully.
HttpError(Error)
The http client encountered an error.