Class: Increase::Models::Simulations::CardPurchaseSupplementCreateParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/increase/models/simulations/card_purchase_supplement_create_params.rb,
sig/increase/models/simulations/card_purchase_supplement_create_params.rbs

Overview

See Also:

  • Increase::Resources::Simulations::CardPurchaseSupplements#create

Defined Under Namespace

Classes: Invoice, LineItem

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(discount_amount: nil, duty_tax_amount: nil, order_date: nil, shipping_amount: nil, shipping_destination_country_code: nil, shipping_destination_postal_code: nil, shipping_source_postal_code: nil, shipping_tax_amount: nil, shipping_tax_rate: nil, unique_value_added_tax_invoice_reference: nil) ⇒ CardPurchaseSupplementCreateParams

Invoice-level information about the payment.

Parameters:

  • discount_amount (Integer) (defaults to: nil) —

    Discount given to cardholder.

  • duty_tax_amount (Integer) (defaults to: nil) —

    Amount of duty taxes.

  • order_date (Date) (defaults to: nil) —

    Date the order was taken.

  • shipping_amount (Integer) (defaults to: nil) —

    The shipping cost.

  • shipping_destination_country_code (String) (defaults to: nil) —

    Country code of the shipping destination.

  • shipping_destination_postal_code (String) (defaults to: nil) —

    Postal code of the shipping destination.

  • shipping_source_postal_code (String) (defaults to: nil) —

    Postal code of the location being shipped from.

  • shipping_tax_amount (Integer) (defaults to: nil) —

    Taxes paid for freight and shipping.

  • shipping_tax_rate (String) (defaults to: nil) —

    Tax rate for freight and shipping.

  • unique_value_added_tax_invoice_reference (String) (defaults to: nil) —

    Value added tax invoice reference number.

  • transaction_id: (String)
  • invoice: (Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice)
  • line_items: (::Array[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem])
  • request_options: (Increase::request_opts)


# File 'lib/increase/models/simulations/card_purchase_supplement_create_params.rb', line 105

Instance Attribute Details

#invoice ⇒ Increase::Models::Simulations::CardPurchaseSupplementCreateParams::Invoice?

Invoice-level information about the payment.

Parameters:

  • (Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice)

Returns:



22
# File 'lib/increase/models/simulations/card_purchase_supplement_create_params.rb', line 22

optional :invoice, -> { Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice }

#line_items ⇒ Array<Increase::Models::Simulations::CardPurchaseSupplementCreateParams::LineItem>?

Line item information, such as individual products purchased.

Parameters:

  • (::Array[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem])

Returns:



28
29
# File 'lib/increase/models/simulations/card_purchase_supplement_create_params.rb', line 28

optional :line_items,
-> { Increase::Internal::Type::ArrayOf[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem] }

#transaction_id ⇒ String

The identifier of the Transaction to create a Card Purchase Supplement for. The Transaction must have a source of type card_settlement.

Parameters:

  • value (String)

Returns:

  • (String)


16
# File 'lib/increase/models/simulations/card_purchase_supplement_create_params.rb', line 16

required :transaction_id, String

Instance Method Details

#to_hash ⇒ { transaction_id: String, invoice: Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice, line_items: ::Array[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem], request_options: Increase::RequestOptions }

Returns:

  • ({ transaction_id: String, invoice: Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice, line_items: ::Array[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem], request_options: Increase::RequestOptions })


37
38
39
40
41
42
# File 'sig/increase/models/simulations/card_purchase_supplement_create_params.rbs', line 37

def to_hash: -> {
  transaction_id: String,
  invoice: Increase::Simulations::CardPurchaseSupplementCreateParams::Invoice,
  line_items: ::Array[Increase::Simulations::CardPurchaseSupplementCreateParams::LineItem],
  request_options: Increase::RequestOptions
}