Class: Clerk::Config
- Inherits:
-
Object
- Object
- Clerk::Config
- Defined in:
- lib/clerk.rb
Constant Summary collapse
- PRODUCTION_BASE_URL =
"https://api.clerk.dev/v1/".freeze
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#base_url ⇒ Object
Returns the value of attribute base_url.
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#middleware_cache_store ⇒ Object
Returns the value of attribute middleware_cache_store.
Instance Method Summary collapse
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
21 22 23 24 |
# File 'lib/clerk.rb', line 21 def initialize @base_url = ENV.fetch("CLERK_API_BASE", PRODUCTION_BASE_URL) @api_key = ENV["CLERK_API_KEY"] end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
19 20 21 |
# File 'lib/clerk.rb', line 19 def api_key @api_key end |
#base_url ⇒ Object
Returns the value of attribute base_url.
19 20 21 |
# File 'lib/clerk.rb', line 19 def base_url @base_url end |
#logger ⇒ Object
Returns the value of attribute logger.
19 20 21 |
# File 'lib/clerk.rb', line 19 def logger @logger end |
#middleware_cache_store ⇒ Object
Returns the value of attribute middleware_cache_store.
19 20 21 |
# File 'lib/clerk.rb', line 19 def middleware_cache_store @middleware_cache_store end |