module PaysonAPI::V1

Constants

CURRENCIES
FEES_PAYERS
FUNDING_CONSTRAINTS
GUARANTEE_OFFERINGS
GUARANTEE_STATUSES
INVOICE_STATUSES
LOCALES
PAYMENT_ACTIONS
PAYMENT_STATUSES
PAYMENT_TYPES
PAYSON_API_ENDPOINT
PAYSON_API_PAYMENT_DETAILS_ACTION
PAYSON_API_PAYMENT_UPDATE_ACTION
PAYSON_API_PAYMENT_VALIDATE_ACTION
PAYSON_API_PAY_ACTION
PAYSON_API_TEST_ENDPOINT
PAYSON_API_VERSION
PAYSON_WWW_HOST_ENDPOINT
PAYSON_WWW_HOST_TEST_ENDPOINT
PAYSON_WWW_PAY_FORWARD_URL

Public Instance Methods

api_base_url() click to toggle source
# File lib/payson_api/v1/config.rb, line 55
def api_base_url
  test? ? PAYSON_API_TEST_ENDPOINT : PAYSON_API_ENDPOINT
end
config() click to toggle source
# File lib/payson_api/v1/config.rb, line 38
def config
  @config
end
configure() { |config ||= configuration| ... } click to toggle source
# File lib/payson_api/v1/config.rb, line 34
def configure
  yield @config ||= Configuration.new # rubocop:disable Naming/MemoizedInstanceVariableName
end
forward_url(token) click to toggle source
# File lib/payson_api/v1/config.rb, line 59
def forward_url(token)
  (test? ? PAYSON_WWW_HOST_TEST_ENDPOINT : PAYSON_WWW_HOST_ENDPOINT) + PAYSON_WWW_PAY_FORWARD_URL % token
end
test?() click to toggle source
# File lib/payson_api/v1/config.rb, line 51
def test?
  @config.test_mode || @config.api_user_id == '4'
end