Class: PaynetEasy::PaynetEasyApi::PaymentData::QueryConfig
- Defined in:
- lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb
Constant Summary collapse
- GATEWAY_MODE_SANDBOX =
Execute query to PaynetEasy sandbox gateway
'sandbox'
- GATEWAY_MODE_PRODUCTION =
Execute query to PaynetEasy production gateway
'production'
- @@allowed_gateway_modes =
Allowed gateway modes
[ GATEWAY_MODE_SANDBOX, GATEWAY_MODE_PRODUCTION ]
Instance Attribute Summary collapse
-
#callback_url ⇒ Object
URL the transaction result will be sent to.
-
#end_point ⇒ Object
Merchant end point.
-
#gateway_mode ⇒ Object
PaynetEasy gateway mode: sandbox or production.
-
#gateway_url_production ⇒ Object
PaynetEasy production gateway URL.
-
#gateway_url_sandbox ⇒ Object
PaynetEasy sandbox gateway URL.
-
#login ⇒ Object
Merchant login.
-
#redirect_url ⇒ Object
URL the customer will be redirected to upon completion of the transaction.
-
#signing_key ⇒ Object
Merchant key for payment signing.
-
#site_url ⇒ Object
URL the original payment is made from.
Instance Method Summary collapse
-
#gateway_url ⇒ String
Get gateway url for current gateway mode.
Methods inherited from Data
Constructor Details
This class inherits a constructor from PaynetEasy::PaynetEasyApi::PaymentData::Data
Instance Attribute Details
#callback_url ⇒ Object
URL the transaction result will be sent to
46 47 48 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 46 def callback_url @callback_url end |
#end_point ⇒ Object
Merchant end point
21 22 23 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 21 def end_point @end_point end |
#gateway_mode ⇒ Object
PaynetEasy gateway mode: sandbox or production
51 52 53 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 51 def gateway_mode @gateway_mode end |
#gateway_url_production ⇒ Object
PaynetEasy production gateway URL
61 62 63 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 61 def gateway_url_production @gateway_url_production end |
#gateway_url_sandbox ⇒ Object
PaynetEasy sandbox gateway URL
56 57 58 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 56 def gateway_url_sandbox @gateway_url_sandbox end |
#login ⇒ Object
Merchant login
26 27 28 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 26 def login @login end |
#redirect_url ⇒ Object
URL the customer will be redirected to upon completion of the transaction
41 42 43 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 41 def redirect_url @redirect_url end |
#signing_key ⇒ Object
Merchant key for payment signing
31 32 33 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 31 def signing_key @signing_key end |
#site_url ⇒ Object
URL the original payment is made from
36 37 38 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 36 def site_url @site_url end |
Instance Method Details
#gateway_url ⇒ String
Get gateway url for current gateway mode
76 77 78 79 80 81 82 |
# File 'lib/paynet_easy/paynet_easy_api/payment_data/query_config.rb', line 76 def gateway_url case gateway_mode when GATEWAY_MODE_SANDBOX then gateway_url_sandbox when GATEWAY_MODE_PRODUCTION then gateway_url_production else raise RuntimeError, 'You must set gateway_mode property first' end end |