Module: Kount
- Defined in:
- lib/kount.rb,
lib/kount/cart.rb,
lib/kount/client.rb,
lib/kount/request.rb,
lib/kount/utils/khash.rb,
lib/kount/payment_types.rb,
lib/kount/security_mash.rb,
lib/kount/request/update.rb,
lib/kount/request/inquiry.rb
Overview
This module is the main entry point to the service wrapper. Its primary function is to collect the runtime options and return a Client object, on which all of the runtime integration takes place.
Defined Under Namespace
Classes: Cart, Client, Inquiry, Khash, PaymentTypes, Request, SecurityMash, Update
Class Method Summary collapse
-
.new(options = {}) ⇒ Object
Creates the client object.
Class Method Details
.new(options = {}) ⇒ Object
Creates the client object
Expected options include:
options = {
:merchant_id => "MERCHANT_ID" # required (6 digit number)
:ksalt => "KSALT" # required (provided by Kount)
:key => "RIS_KEY" # required (created in the AWC web app)
:endpoint => "RIS_ENDPOINT" # optional (default https://risk.kount.net)
:version => "RIS_VERSION" # optional (defaults "0630")
:is_test => "IS_TEST" # optional (defaults to false)
}
23 24 25 26 27 28 |
# File 'lib/kount.rb', line 23 def new( = {}) @logger = Logger.new("Logs.log") raise ArgumentError, 'Config options required' if .empty? @logger.info("Options passed by client : #{}") Client.new() end |