Class: CheckoutSdk::Forex::ForexClient

Inherits:
Client
  • Object
show all
Defined in:
lib/checkout_sdk/forex/forex_client.rb

Instance Attribute Summary

Attributes inherited from Client

#api_client, #authorization_type, #configuration

Instance Method Summary collapse

Constructor Details

#initialize(api_client, configuration) ⇒ ForexClient

Returns a new instance of ForexClient.

Parameters:



13
14
15
# File 'lib/checkout_sdk/forex/forex_client.rb', line 13

def initialize(api_client, configuration)
  super(api_client, configuration, CheckoutSdk::AuthorizationType::OAUTH)
end

Instance Method Details

#get_rates(rates_query_filter) ⇒ Object

Parameters:



23
24
25
# File 'lib/checkout_sdk/forex/forex_client.rb', line 23

def get_rates(rates_query_filter)
  api_client.invoke_get(build_path(FOREX, RATES), sdk_authorization, rates_query_filter)
end

#request_quote(quote_request) ⇒ Object

Parameters:



18
19
20
# File 'lib/checkout_sdk/forex/forex_client.rb', line 18

def request_quote(quote_request)
  api_client.invoke_post(build_path(FOREX, QUOTES), sdk_authorization, quote_request)
end