Class: Minfraud::Components::Event
- Includes:
- Enum
- Defined in:
- lib/minfraud/components/event.rb
Instance Attribute Summary collapse
-
#shop_id ⇒ String
Internal ID for the shop, affiliate, or merchant this order is coming from.
-
#time ⇒ String
If this field is not in the request, the current time will be used.
-
#transaction_id ⇒ String
Internal ID for the transaction.
-
#type ⇒ String
The type of event being scored.
Instance Method Summary collapse
-
#initialize(params = {}) ⇒ Minfraud::Components::Event
constructor
Creates Minfraud::Components::Event instance.
Methods included from Enum
Methods inherited from Base
Constructor Details
#initialize(params = {}) ⇒ Minfraud::Components::Event
Creates Minfraud::Components::Event instance
31 32 33 34 35 36 |
# File 'lib/minfraud/components/event.rb', line 31 def initialize(params = {}) @transaction_id = params[:transaction_id] @shop_id = params[:shop_id] @time = params[:time] @type = params[:type] end |
Instance Attribute Details
#shop_id ⇒ String
Returns Internal ID for the shop, affiliate, or merchant this order is coming from.
11 12 13 |
# File 'lib/minfraud/components/event.rb', line 11 def shop_id @shop_id end |
#time ⇒ String
If this field is not in the request, the current time will be used
16 17 18 |
# File 'lib/minfraud/components/event.rb', line 16 def time @time end |
#transaction_id ⇒ String
Returns Internal ID for the transaction. Used to locate a specific transaction in minFraud logs.
7 8 9 |
# File 'lib/minfraud/components/event.rb', line 7 def transaction_id @transaction_id end |
#type ⇒ String
Returns The type of event being scored. The valid types are:
> account_creation
> account_login
> purchase
> recurring_purchase
> referral
> survey.
26 |
# File 'lib/minfraud/components/event.rb', line 26 enum_accessor :type, [:account_creation, :account_login, :purchase, :recurring_purchase, :referral, :survey] |