Class: Gemini::Configuration
- Inherits:
-
Object
- Object
- Gemini::Configuration
- Defined in:
- lib/gemini.rb
Constant Summary collapse
- DEFAULT_URI_BASE =
"https://generativelanguage.googleapis.com/v1beta".freeze
- DEFAULT_REQUEST_TIMEOUT =
120- DEFAULT_LOG_ERRORS =
false
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#extra_headers ⇒ Object
Returns the value of attribute extra_headers.
-
#log_errors ⇒ Object
Returns the value of attribute log_errors.
-
#request_timeout ⇒ Object
Returns the value of attribute request_timeout.
-
#uri_base ⇒ Object
Returns the value of attribute uri_base.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
53 54 55 56 57 58 59 |
# File 'lib/gemini.rb', line 53 def initialize @api_key = nil @log_errors = DEFAULT_LOG_ERRORS @uri_base = DEFAULT_URI_BASE @request_timeout = DEFAULT_REQUEST_TIMEOUT @extra_headers = {} end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
43 44 45 |
# File 'lib/gemini.rb', line 43 def api_key @api_key end |
#extra_headers ⇒ Object
Returns the value of attribute extra_headers.
43 44 45 |
# File 'lib/gemini.rb', line 43 def extra_headers @extra_headers end |
#log_errors ⇒ Object
Returns the value of attribute log_errors.
43 44 45 |
# File 'lib/gemini.rb', line 43 def log_errors @log_errors end |
#request_timeout ⇒ Object
Returns the value of attribute request_timeout.
43 44 45 |
# File 'lib/gemini.rb', line 43 def request_timeout @request_timeout end |
#uri_base ⇒ Object
Returns the value of attribute uri_base.
43 44 45 |
# File 'lib/gemini.rb', line 43 def uri_base @uri_base end |