Pristine.Core.Context (Pristine v0.3.1)

Copy Markdown View Source

Internal runtime context for executing request specs.

Pristine.Client is the public runtime client contract.

Summary

Types

t()

@type t() :: %Pristine.Core.Context{
  admission_control: module() | nil,
  admission_opts: keyword(),
  auth: list(),
  base_url: String.t() | nil,
  circuit_breaker: module() | nil,
  circuit_breaker_opts: keyword(),
  config: term() | nil,
  default_query: map(),
  default_timeout: non_neg_integer() | nil,
  dump_headers?: boolean(),
  error_module: module() | nil,
  extra_headers: function() | nil,
  governed_authority: Pristine.GovernedAuthority.t() | nil,
  headers: map(),
  idempotency_header: String.t(),
  log_level: :debug | :info | :warn | :error | nil,
  logger: (atom(), String.t(), map() -> term()) | nil,
  multipart: module() | nil,
  multipart_opts: keyword(),
  package_version: String.t() | nil,
  pool_base: term() | nil,
  pool_manager: module() | nil,
  provider_profile: term() | nil,
  query_opts: keyword(),
  rate_limit_opts: keyword(),
  rate_limiter: module() | nil,
  redact_headers: function() | nil,
  response_wrapper: module() | nil,
  result_classifier: module() | function() | nil,
  retry: module() | nil,
  retry_opts: keyword(),
  retry_policies: map(),
  semaphore: module() | nil,
  serializer: module() | nil,
  stream_transport: module() | nil,
  streaming: module() | nil,
  telemetry: module() | nil,
  telemetry_events: map(),
  telemetry_metadata: map(),
  transform_opts: keyword(),
  transport: module() | nil,
  transport_opts: keyword(),
  type_schemas: map()
}

Functions

new(opts \\ [])

@spec new(keyword()) :: t()