Class: Orb::Models::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::Increment::InvoiceSettings
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Orb::Models::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::Increment::InvoiceSettings
- Defined in:
- lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb,
sig/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbs
Overview
Defined Under Namespace
Modules: CustomDueDate, InvoiceDate
Instance Attribute Summary collapse
-
#auto_collection ⇒ Boolean
Whether the credits purchase invoice should auto collect with the customer's saved payment method.
-
#custom_due_date ⇒ Date, ...
An optional custom due date for the invoice.
-
#invoice_date ⇒ Date, ...
An ISO 8601 format date that denotes when this invoice should be dated in the customer's timezone.
-
#item_id ⇒ String?
The ID of the Item to be used for the invoice line item.
-
#mark_as_paid ⇒ Boolean?
If true, the new credits purchase invoice will be marked as paid.
-
#memo ⇒ String?
An optional memo to display on the invoice.
-
#net_terms ⇒ Integer?
The net terms determines the due date of the invoice.
-
#require_successful_payment ⇒ Boolean?
If true, the new credit block will require that the corresponding invoice is paid before it can be drawn down from.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(auto_collection:, custom_due_date: nil, invoice_date: nil, item_id: nil, mark_as_paid: nil, memo: nil, net_terms: nil, require_successful_payment: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see InvoiceSettings for more details.
- #to_hash ⇒ {
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(auto_collection:, custom_due_date: nil, invoice_date: nil, item_id: nil, mark_as_paid: nil, memo: nil, net_terms: nil, require_successful_payment: nil) ⇒ Object
Some parameter documentations has been truncated, see Orb::Models::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::Increment::InvoiceSettings for more details.
Passing invoice_settings automatically generates an invoice for the newly
added credits. If invoice_settings is passed, you must specify
per_unit_cost_basis, as the calculation of the invoice total is done on that
basis.
|
|
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 273
|
Instance Attribute Details
#auto_collection ⇒ Boolean
Whether the credits purchase invoice should auto collect with the customer's saved payment method.
211 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 211 required :auto_collection, Orb::Internal::Type::Boolean |
#custom_due_date ⇒ Date, ...
An optional custom due date for the invoice. If not set, the due date will be
calculated based on the net_terms value.
218 219 220 221 222 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 218 optional :custom_due_date, union: -> { Orb::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::Increment::InvoiceSettings::CustomDueDate }, nil?: true |
#invoice_date ⇒ Date, ...
An ISO 8601 format date that denotes when this invoice should be dated in the customer's timezone. If not provided, the invoice date will default to the credit block's effective date.
230 231 232 233 234 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 230 optional :invoice_date, union: -> { Orb::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::Increment::InvoiceSettings::InvoiceDate }, nil?: true |
#item_id ⇒ String?
The ID of the Item to be used for the invoice line item. If not provided, a default 'Credits' item will be used.
241 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 241 optional :item_id, String, nil?: true |
#mark_as_paid ⇒ Boolean?
If true, the new credits purchase invoice will be marked as paid.
247 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 247 optional :mark_as_paid, Orb::Internal::Type::Boolean |
#memo ⇒ String?
An optional memo to display on the invoice.
253 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 253 optional :memo, String, nil?: true |
#net_terms ⇒ Integer?
The net terms determines the due date of the invoice. Due date is calculated
based on the invoice or issuance date, depending on the account's configured due
date calculation method. A value of '0' here represents that the invoice is due
on issue, whereas a value of '30' represents that the customer has 30 days to
pay the invoice. You must set either net_terms or custom_due_date, but not
both.
264 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 264 optional :net_terms, Integer, nil?: true |
#require_successful_payment ⇒ Boolean?
If true, the new credit block will require that the corresponding invoice is paid before it can be drawn down from.
271 |
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 271 optional :require_successful_payment, Orb::Internal::Type::Boolean |
Class Method Details
.variants ⇒ Array(Date, Time)
|
|
# File 'lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb', line 310
|
Instance Method Details
#to_hash ⇒ {
195 |
# File 'sig/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbs', line 195
def to_hash: -> {
|