Class: Orb::Models::CreditNote
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Orb::Models::CreditNote
- Defined in:
- lib/orb/models/credit_note.rb
Defined Under Namespace
Modules: Reason, Type Classes: Discount, LineItem, MaximumAmountAdjustment
Instance Attribute Summary collapse
-
#created_at ⇒ Time
The creation time of the resource in Orb.
-
#credit_note_number ⇒ String
The unique identifier for credit notes.
-
#credit_note_pdf ⇒ String?
A URL to a PDF of the credit note.
- #customer ⇒ Orb::Models::CustomerMinified
-
#discounts ⇒ Array<Orb::Models::CreditNote::Discount>?
Any discounts applied on the original invoice.
-
#id ⇒ String
The Orb id of this credit note.
-
#invoice_id ⇒ String
The id of the invoice resource that this credit note is applied to.
-
#line_items ⇒ Array<Orb::Models::CreditNote::LineItem>
All of the line items associated with this credit note.
-
#maximum_amount_adjustment ⇒ Orb::Models::CreditNote::MaximumAmountAdjustment?
The maximum amount applied on the original invoice.
-
#memo ⇒ String?
An optional memo supplied on the credit note.
-
#minimum_amount_refunded ⇒ String?
Any credited amount from the applied minimum on the invoice.
- #reason ⇒ Symbol, ...
-
#subtotal ⇒ String
The total prior to any creditable invoice-level discounts or minimums.
-
#total ⇒ String
The total including creditable invoice-level discounts or minimums, and tax.
- #type ⇒ Symbol, Orb::Models::CreditNote::Type
-
#voided_at ⇒ Time?
The time at which the credit note was voided in Orb, if applicable.
Class Method Summary collapse
Instance Method Summary collapse
- #initialize(id: , name: ) ⇒ Object constructor
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(id: , name: ) ⇒ Object
|
|
# File 'lib/orb/models/credit_note.rb', line 336
|
Instance Attribute Details
#created_at ⇒ Time
The creation time of the resource in Orb.
16 |
# File 'lib/orb/models/credit_note.rb', line 16 required :created_at, Time |
#credit_note_number ⇒ String
The unique identifier for credit notes.
22 |
# File 'lib/orb/models/credit_note.rb', line 22 required :credit_note_number, String |
#credit_note_pdf ⇒ String?
A URL to a PDF of the credit note.
28 |
# File 'lib/orb/models/credit_note.rb', line 28 required :credit_note_pdf, String, nil?: true |
#customer ⇒ Orb::Models::CustomerMinified
33 |
# File 'lib/orb/models/credit_note.rb', line 33 required :customer, -> { Orb::CustomerMinified } |
#discounts ⇒ Array<Orb::Models::CreditNote::Discount>?
Any discounts applied on the original invoice.
97 |
# File 'lib/orb/models/credit_note.rb', line 97 optional :discounts, -> { Orb::Internal::Type::ArrayOf[Orb::CreditNote::Discount] } |
#id ⇒ String
The Orb id of this credit note.
10 |
# File 'lib/orb/models/credit_note.rb', line 10 required :id, String |
#invoice_id ⇒ String
The id of the invoice resource that this credit note is applied to.
39 |
# File 'lib/orb/models/credit_note.rb', line 39 required :invoice_id, String |
#line_items ⇒ Array<Orb::Models::CreditNote::LineItem>
All of the line items associated with this credit note.
45 |
# File 'lib/orb/models/credit_note.rb', line 45 required :line_items, -> { Orb::Internal::Type::ArrayOf[Orb::CreditNote::LineItem] } |
#maximum_amount_adjustment ⇒ Orb::Models::CreditNote::MaximumAmountAdjustment?
The maximum amount applied on the original invoice
51 |
# File 'lib/orb/models/credit_note.rb', line 51 required :maximum_amount_adjustment, -> { Orb::CreditNote::MaximumAmountAdjustment }, nil?: true |
#memo ⇒ String?
An optional memo supplied on the credit note.
57 |
# File 'lib/orb/models/credit_note.rb', line 57 required :memo, String, nil?: true |
#minimum_amount_refunded ⇒ String?
Any credited amount from the applied minimum on the invoice.
63 |
# File 'lib/orb/models/credit_note.rb', line 63 required :minimum_amount_refunded, String, nil?: true |
#reason ⇒ Symbol, ...
68 |
# File 'lib/orb/models/credit_note.rb', line 68 required :reason, enum: -> { Orb::CreditNote::Reason }, nil?: true |
#subtotal ⇒ String
The total prior to any creditable invoice-level discounts or minimums.
74 |
# File 'lib/orb/models/credit_note.rb', line 74 required :subtotal, String |
#total ⇒ String
The total including creditable invoice-level discounts or minimums, and tax.
80 |
# File 'lib/orb/models/credit_note.rb', line 80 required :total, String |
#type ⇒ Symbol, Orb::Models::CreditNote::Type
85 |
# File 'lib/orb/models/credit_note.rb', line 85 required :type, enum: -> { Orb::CreditNote::Type } |
#voided_at ⇒ Time?
The time at which the credit note was voided in Orb, if applicable.
91 |
# File 'lib/orb/models/credit_note.rb', line 91 required :voided_at, Time, nil?: true |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/orb/models/credit_note.rb', line 269
|