Class: Remit::API
- Inherits:
-
Relax::Service
- Object
- Relax::Service
- Remit::API
- Includes:
- Cancel, CancelSubscriptionAndRefund, CancelToken, DiscardResults, FundPrepaid, GetAccountActivity, GetAccountBalance, GetAllCreditInstruments, GetAllPrepaidInstruments, GetDebtBalance, GetOutstandingDebtBalance, GetPaymentInstruction, GetPipeline, GetPrepaidBalance, GetResults, GetTokenByCaller, GetTokenUsage, GetTokens, GetTotalPrepaidLiability, GetTransaction, InstallPaymentInstruction, Pay, Refund, Reserve, RetryTransaction, Settle, SettleDebt, SubscribeForCallerNotification, UnsubscribeForCallerNotification, WriteOffDebt
- Defined in:
- lib/remit.rb
Constant Summary collapse
- API_ENDPOINT =
'https://fps.amazonaws.com/'.freeze
- API_SANDBOX_ENDPOINT =
'https://fps.sandbox.amazonaws.com/'.freeze
- PIPELINE_URL =
'https://authorize.payments.amazon.com/cobranded-ui/actions/start'.freeze
- PIPELINE_SANDBOX_URL =
'https://authorize.payments-sandbox.amazon.com/cobranded-ui/actions/start'.freeze
- API_VERSION =
Date.new(2007, 1, 8).to_s.freeze
- SIGNATURE_VERSION =
1.freeze
Instance Attribute Summary collapse
-
#access_key ⇒ Object
readonly
Returns the value of attribute access_key.
-
#pipeline_url ⇒ Object
readonly
Returns the value of attribute pipeline_url.
-
#secret_key ⇒ Object
readonly
Returns the value of attribute secret_key.
Instance Method Summary collapse
-
#initialize(access_key, secret_key, sandbox = false) ⇒ API
constructor
A new instance of API.
Methods included from WriteOffDebt
Methods included from UnsubscribeForCallerNotification
#unsubscribe_for_caller_notification
Methods included from SubscribeForCallerNotification
#subscribe_for_caller_notification
Methods included from SettleDebt
Methods included from Settle
Methods included from RetryTransaction
Methods included from Reserve
Methods included from Refund
Methods included from Pay
Methods included from InstallPaymentInstruction
Methods included from GetTransaction
Methods included from GetTotalPrepaidLiability
Methods included from GetTokenByCaller
Methods included from GetTokens
Methods included from GetTokenUsage
Methods included from GetResults
Methods included from GetPrepaidBalance
Methods included from GetPipeline
#get_multi_use_pipeline, #get_pipeline, #get_postpaid_pipeline, #get_recipient_pipeline, #get_recurring_use_pipeline, #get_single_use_pipeline
Methods included from GetPaymentInstruction
Methods included from GetOutstandingDebtBalance
Methods included from GetDebtBalance
Methods included from GetAllPrepaidInstruments
Methods included from GetAllCreditInstruments
Methods included from GetAccountBalance
Methods included from GetAccountActivity
Methods included from FundPrepaid
Methods included from DiscardResults
Methods included from Cancel
Methods included from CancelToken
Methods included from CancelSubscriptionAndRefund
#cancel_subscription_and_refund
Constructor Details
#initialize(access_key, secret_key, sandbox = false) ⇒ API
Returns a new instance of API.
96 97 98 99 100 101 102 |
# File 'lib/remit.rb', line 96 def initialize(access_key, secret_key, sandbox=false) @access_key = access_key @secret_key = secret_key @pipeline_url = sandbox ? PIPELINE_SANDBOX_URL : PIPELINE_URL super(sandbox ? API_SANDBOX_ENDPOINT : API_ENDPOINT) end |
Instance Attribute Details
#access_key ⇒ Object (readonly)
Returns the value of attribute access_key.
92 93 94 |
# File 'lib/remit.rb', line 92 def access_key @access_key end |
#pipeline_url ⇒ Object (readonly)
Returns the value of attribute pipeline_url.
94 95 96 |
# File 'lib/remit.rb', line 94 def pipeline_url @pipeline_url end |
#secret_key ⇒ Object (readonly)
Returns the value of attribute secret_key.
93 94 95 |
# File 'lib/remit.rb', line 93 def secret_key @secret_key end |