Class: ModernTreasury::Models::InvoiceUpdateParams::InvoiceLineItem

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/modern_treasury/models/invoice_update_params.rb

Instance Attribute Summary collapse

Method Summary

Methods inherited from Internal::Type::BaseModel

#==, ==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, #initialize, 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

This class inherits a constructor from ModernTreasury::Internal::Type::BaseModel

Instance Attribute Details

#descriptionString?

An optional free-form description of the line item.

Returns:

  • (String, nil)


367
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 367

optional :description, String

#directionString?

Either ‘debit` or `credit`. `debit` indicates that a client owes the business money and increases the invoice’s ‘total_amount` due. `credit` has the opposite intention and effect.

Returns:

  • (String, nil)


375
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 375

optional :direction, String

#metadataHash{Symbol=>String}?

Additional data represented as key-value pairs. Both the key and value must be strings.

Returns:

  • (Hash{Symbol=>String}, nil)


382
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 382

optional :metadata, ModernTreasury::Internal::Type::HashOf[String]

#nameString

The name of the line item, typically a product or SKU name.

Returns:

  • (String)


354
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 354

required :name, String

#quantityInteger?

The number of units of a product or service that this line item is for. Must be a whole number. Defaults to 1 if not provided.

Returns:

  • (Integer, nil)


389
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 389

optional :quantity, Integer

#unit_amountInteger

The cost per unit of the product or service that this line item is for, specified in the invoice currency’s smallest unit.

Returns:

  • (Integer)


361
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 361

required :unit_amount, Integer

#unit_amount_decimalString?

The cost per unit of the product or service that this line item is for, specified in the invoice currency’s smallest unit. Accepts decimal strings with up to 12 decimals

Returns:

  • (String, nil)


397
# File 'lib/modern_treasury/models/invoice_update_params.rb', line 397

optional :unit_amount_decimal, String