Class: Google::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionData

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/recaptchaenterprise_v1/classes.rb,
lib/google/apis/recaptchaenterprise_v1/representations.rb,
lib/google/apis/recaptchaenterprise_v1/representations.rb

Overview

Transaction data associated with a payment protected by reCAPTCHA Enterprise.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRecaptchaenterpriseV1TransactionData

Returns a new instance of GoogleCloudRecaptchaenterpriseV1TransactionData.



1612
1613
1614
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1612

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#billing_addressGoogle::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataAddress

Structured address format for billing and shipping addresses. Corresponds to the JSON property billingAddress



1542
1543
1544
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1542

def billing_address
  @billing_address
end

#card_binString

Optional. The Bank Identification Number - generally the first 6 or 8 digits of the card. Corresponds to the JSON property cardBin

Returns:

  • (String)


1548
1549
1550
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1548

def card_bin
  @card_bin
end

#card_last_fourString

Optional. The last four digits of the card. Corresponds to the JSON property cardLastFour

Returns:

  • (String)


1553
1554
1555
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1553

def card_last_four
  @card_last_four
end

#currency_codeString

Optional. The currency code in ISO-4217 format. Corresponds to the JSON property currencyCode

Returns:

  • (String)


1558
1559
1560
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1558

def currency_code
  @currency_code
end

#gateway_infoGoogle::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataGatewayInfo

Details about the transaction from the gateway. Corresponds to the JSON property gatewayInfo



1563
1564
1565
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1563

def gateway_info
  @gateway_info
end

#itemsArray<Google::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataItem>

Optional. Items purchased in this transaction. Corresponds to the JSON property items



1568
1569
1570
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1568

def items
  @items
end

#merchantsArray<Google::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataUser>

Optional. Information about the user or users fulfilling the transaction. Corresponds to the JSON property merchants



1573
1574
1575
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1573

def merchants
  @merchants
end

#payment_methodString

Optional. The payment method for the transaction. The allowed values are: * credit-card * debit-card * gift-card * processor-name (If a third-party is used, for example, processor-paypal) * custom-name (If an alternative method is used, for example, custom-crypto) Corresponds to the JSON property paymentMethod

Returns:

  • (String)


1581
1582
1583
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1581

def payment_method
  @payment_method
end

#shipping_addressGoogle::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataAddress

Structured address format for billing and shipping addresses. Corresponds to the JSON property shippingAddress



1586
1587
1588
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1586

def shipping_address
  @shipping_address
end

#shipping_valueFloat

Optional. The value of shipping in the specified currency. 0 for free or no shipping. Corresponds to the JSON property shippingValue

Returns:

  • (Float)


1592
1593
1594
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1592

def shipping_value
  @shipping_value
end

#transaction_idString

Unique identifier for the transaction. This custom identifier can be used to reference this transaction in the future, for example, labeling a refund or chargeback event. Two attempts at the same transaction should use the same transaction id. Corresponds to the JSON property transactionId

Returns:

  • (String)


1600
1601
1602
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1600

def transaction_id
  @transaction_id
end

#userGoogle::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataUser

Details about a user's account involved in the transaction. Corresponds to the JSON property user



1605
1606
1607
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1605

def user
  @user
end

#valueFloat

Optional. The decimal value of the transaction in the specified currency. Corresponds to the JSON property value

Returns:

  • (Float)


1610
1611
1612
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1610

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 1617

def update!(**args)
  @billing_address = args[:billing_address] if args.key?(:billing_address)
  @card_bin = args[:card_bin] if args.key?(:card_bin)
  @card_last_four = args[:card_last_four] if args.key?(:card_last_four)
  @currency_code = args[:currency_code] if args.key?(:currency_code)
  @gateway_info = args[:gateway_info] if args.key?(:gateway_info)
  @items = args[:items] if args.key?(:items)
  @merchants = args[:merchants] if args.key?(:merchants)
  @payment_method = args[:payment_method] if args.key?(:payment_method)
  @shipping_address = args[:shipping_address] if args.key?(:shipping_address)
  @shipping_value = args[:shipping_value] if args.key?(:shipping_value)
  @transaction_id = args[:transaction_id] if args.key?(:transaction_id)
  @user = args[:user] if args.key?(:user)
  @value = args[:value] if args.key?(:value)
end