Attio.Error (Attio v0.2.0)

Copy Markdown View Source

Represents an error response from the Attio API.

All four fields are populated from the JSON error body returned by the API:

%Attio.Error{
  status: 404,
  type: "invalid_request_error",
  code: "not_found",
  message: "Object 'foobar' not found."
}

Transport errors (connection failures, timeouts) are returned as the underlying exception rather than Attio.Error.

Summary

Types

t()

@type t() :: %Attio.Error{
  code: String.t(),
  message: String.t(),
  status: non_neg_integer(),
  type: String.t()
}