Klaviyo.Response (klaviyo v3.1.0)

HTTP response returned by a request.

Summary

Types

@type t() :: %Klaviyo.Response{
  body: map(),
  headers: Klaviyo.HTTP.headers_t(),
  status_code: Klaviyo.HTTP.status_code_t()
}

Functions

Link to this function

new(response, opts)

Builds a Klaviyo.Response struct.

Only decodes the body of a response if the value of the "content-type" header is supported. Otherwise, the body will be returned as is.

Supported Encodings

  • application/json