pub struct CreditNote {Show 25 fields
pub lago_id: Uuid,
pub sequential_id: i32,
pub number: String,
pub lago_invoice_id: Uuid,
pub invoice_number: String,
pub issuing_date: String,
pub credit_status: Option<CreditNoteCreditStatus>,
pub refund_status: Option<CreditNoteRefundStatus>,
pub reason: CreditNoteReason,
pub description: Option<String>,
pub currency: String,
pub total_amount_cents: i64,
pub taxes_amount_cents: i64,
pub taxes_rate: f64,
pub sub_total_excluding_taxes_amount_cents: i64,
pub balance_amount_cents: i64,
pub credit_amount_cents: i64,
pub refund_amount_cents: i64,
pub coupons_adjustment_amount_cents: i64,
pub file_url: Option<String>,
pub self_billed: Option<bool>,
pub created_at: DateTime<Utc>,
pub updated_at: DateTime<Utc>,
pub items: Option<Vec<CreditNoteItem>>,
pub applied_taxes: Option<Vec<CreditNoteAppliedTax>>,
}Expand description
Represents a credit note in the Lago billing system.
Credit notes are issued to refund or credit customers for invoices, either partially or in full.
Fields§
§lago_id: UuidUnique identifier for the credit note in Lago
sequential_id: i32Sequential identifier for the credit note
number: StringCredit note number (e.g., “LAG-1234-CN-001”)
lago_invoice_id: UuidLago ID of the related invoice
invoice_number: StringNumber of the related invoice
issuing_date: StringDate when the credit note was issued
credit_status: Option<CreditNoteCreditStatus>Status of the credit (available, consumed, voided)
refund_status: Option<CreditNoteRefundStatus>Status of the refund (pending, succeeded, failed)
reason: CreditNoteReasonReason for the credit note
description: Option<String>Optional description for the credit note
currency: StringCurrency code (ISO 4217)
total_amount_cents: i64Total amount in cents
taxes_amount_cents: i64Tax amount in cents
taxes_rate: f64Tax rate percentage
sub_total_excluding_taxes_amount_cents: i64Subtotal excluding taxes in cents
balance_amount_cents: i64Remaining balance in cents
credit_amount_cents: i64Credit amount in cents
refund_amount_cents: i64Refund amount in cents
coupons_adjustment_amount_cents: i64Coupon adjustment amount in cents
file_url: Option<String>URL to the generated PDF file
self_billed: Option<bool>Whether this is a self-billed credit note
created_at: DateTime<Utc>Creation timestamp
updated_at: DateTime<Utc>Last update timestamp
items: Option<Vec<CreditNoteItem>>Line items for the credit note
applied_taxes: Option<Vec<CreditNoteAppliedTax>>Applied taxes
Trait Implementations§
Source§impl Clone for CreditNote
impl Clone for CreditNote
Source§fn clone(&self) -> CreditNote
fn clone(&self) -> CreditNote
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more