Class: Colppy::Core::Gateway

Inherits:
Object
  • Object
show all
Defined in:
lib/colppy/core/gateway.rb

Constant Summary collapse

MODES =
%w(live sandbox).freeze
MIME_JSON =
"application/json".freeze
SANDBOX_API_URL =
"http://staging.colppy.com".freeze
PRODUCTION_API_URL =
"https://login.colppy.com".freeze
API_PATH =
"/lib/frontera2/service.php".freeze

Instance Method Summary collapse

Constructor Details

#initialize(mode = "sandbox") ⇒ Gateway

Returns a new instance of Gateway.



10
11
12
# File 'lib/colppy/core/gateway.rb', line 10

def initialize(mode = "sandbox")
  @mode = mode
end

Instance Method Details

#call(payload = {}) ⇒ Object



22
23
24
# File 'lib/colppy/core/gateway.rb', line 22

def call(payload = {})
  make_request(payload)
end