Module: EuPago::Api

Defined in:
lib/ruby-eupago/api.rb,
lib/ruby-eupago/api/v1.rb,
lib/ruby-eupago/api/auth.rb,
lib/ruby-eupago/api/v1/mbway.rb,
lib/ruby-eupago/api/v1/payouts.rb,
lib/ruby-eupago/api/v1/references.rb,
lib/ruby-eupago/api/v1/credit_card.rb,
lib/ruby-eupago/api/v1/direct_debit.rb

Defined Under Namespace

Modules: Auth, V1

Class Method Summary collapse

Class Method Details

.body_clientObject

3 - API Key sent as a body param



16
17
18
# File 'lib/ruby-eupago/api.rb', line 16

def self.body_client
  @body_client ||= EuPago::Client.new({ include_api_key: false, include_api_key_in_body: true })
end

.clientObject

EuPago current REST API uses three different types of authentication:

1 - ApiKey Auth (API Key sent as an header param)



6
7
8
# File 'lib/ruby-eupago/api.rb', line 6

def self.client
  @client ||= EuPago::Client.new({ include_api_key: true, prefix_base_url: "/api/v1.02" })
end

.oauth_clientObject

2 -OAuth 2.0 (Bearer Token sent as an header param)



11
12
13
# File 'lib/ruby-eupago/api.rb', line 11

def self.oauth_client
  @oauth_client ||= EuPago::OAuthClient.new({ prefix_base_url: "/api" })
end