Timber v1.0.4 Timber.Events.HTTPClientResponseEvent

The HTTPClientResponseEvent tracks responses for outgoing HTTP requests. This gives you structured insight into communication with external services.

See Timber.Events.HTTPClientRequestEvent for examples on track the entire HTTP request lifecycle.

Summary

Functions

Message to be used when logging

Builds a new struct taking care to normalize data into a valid state. This should be used, where possible, instead of creating the struct directly

Convenience methods for creating an event and getting the message at the same time

Types

headers()
headers :: %{cache_control: String.t, content_disposition: String.t, content_length: non_neg_integer, content_type: String.t, location: String.t, request_id: String.t}
t()
t :: %Timber.Events.HTTPClientResponseEvent{headers: headers, status: pos_integer, time_ms: float}

Functions

message(h_t_t_p_client_response_event)
message(t) :: IO.chardata

Message to be used when logging.

new(opts)
new(Keyword.t) :: t

Builds a new struct taking care to normalize data into a valid state. This should be used, where possible, instead of creating the struct directly.

new_with_message(opts)
new_with_message(Keyword.t) :: {t, IO.chardata}

Convenience methods for creating an event and getting the message at the same time.