Class: CoreLibrary::ApiRequestLoggingConfiguration

Inherits:
BaseHttpLoggingConfiguration show all
Defined in:
lib/apimatic-core/logger/configurations/api_logging_configuration.rb

Overview

Represents request logging configuration.

Instance Attribute Summary collapse

Attributes inherited from BaseHttpLoggingConfiguration

#headers_to_exclude, #headers_to_include, #headers_to_unmask, #log_body, #log_headers

Instance Method Summary collapse

Constructor Details

#initialize(log_body, log_headers, headers_to_exclude, headers_to_include, headers_to_unmask, include_query_in_path) ⇒ ApiRequestLoggingConfiguration

Initializes a new instance of ApiRequestLoggingConfiguration.

Parameters:

  • log_body (Boolean)

    Indicates whether the message body should be logged. Default is false.

  • log_headers (Boolean)

    Indicates whether the message headers should be logged. Default is false.

  • headers_to_exclude (Array<String>)

    Array of headers not displayed in logging. Default is an empty array.

  • headers_to_include (Array<String>)

    Array of headers to be displayed in logging. Default is an empty array.

  • headers_to_unmask (Array<String>)

    Array of headers which values are non-sensitive to display in logging. Default is an empty array.



67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# File 'lib/apimatic-core/logger/configurations/api_logging_configuration.rb', line 67

def initialize(
  log_body,
  log_headers,
  headers_to_exclude,
  headers_to_include,
  headers_to_unmask,
  include_query_in_path
)
  super(
    log_body,
    log_headers,
    headers_to_exclude,
    headers_to_include,
    headers_to_unmask
  )
  @include_query_in_path = include_query_in_path
end

Instance Attribute Details

#include_query_in_pathObject (readonly)

Returns the value of attribute include_query_in_path.



57
58
59
# File 'lib/apimatic-core/logger/configurations/api_logging_configuration.rb', line 57

def include_query_in_path
  @include_query_in_path
end