Class: Ecko::Plugins::Stripe::Configurations

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/ecko/plugins/stripe/configurations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#schemaObject

Returns the value of attribute schema.



8
9
10
# File 'lib/ecko/plugins/stripe/configurations.rb', line 8

def schema
  @schema
end

Instance Method Details

#callbackObject

Callback url which helps in returning to the correct url when a payment is complete or cancelled



32
33
34
# File 'lib/ecko/plugins/stripe/configurations.rb', line 32

def callback
  schema[:callback]
end

#currencyObject

Configured currency while checkout process.



26
27
28
# File 'lib/ecko/plugins/stripe/configurations.rb', line 26

def currency
  schema[:currency] || 'USD'
end

#setup(schema) ⇒ Object



10
11
12
# File 'lib/ecko/plugins/stripe/configurations.rb', line 10

def setup(schema)
  @schema = schema
end

#state_secretObject

The state secret is used if we have to encrypt any state on callbacks Currently this hasn’t been used.



21
22
23
# File 'lib/ecko/plugins/stripe/configurations.rb', line 21

def state_secret
  schema[:state_secret]
end

#stripe_api_keyObject

Stripe API key configured through schema



15
16
17
# File 'lib/ecko/plugins/stripe/configurations.rb', line 15

def stripe_api_key
  schema[:stripe_api_key]
end