View Source Kevo.ApiError exception (kevo_ex v0.2.1)

Represents a failed response from Kevo's HTTP/2 API.

Summary

Types

@type t() :: %Kevo.ApiError{
  __exception__: true,
  caused_by: any(),
  expected: integer() | [{String.t(), String.t()}],
  reason: :network_error | :unexpected_status | :unexpected_body,
  request: map(),
  response: any(),
  step: {function :: String.t(), arity :: integer()}
}

Functions

Link to this function

from_body(request, error, step \\ nil)

View Source
Link to this function

from_headers(request, response, expected, step \\ nil)

View Source
Link to this function

from_network(request, error, step \\ nil)

View Source
Link to this function

from_status(request, response, expected, step \\ nil)

View Source

Callback implementation for Exception.message/1.