WAservix.Error exception (WAservix v1.0.0)

Copy Markdown View Source

Returned when the API answers with an error, or the request fails.

status is the HTTP status (0 when the request never reached the API). A 503 means the device is reconnecting: retry shortly. retry_after is set after a 429.

Summary

Types

t()

@type t() :: %WAservix.Error{
  __exception__: true,
  body: term(),
  errors: map() | nil,
  message: String.t(),
  retry_after: number() | nil,
  status: non_neg_integer()
}