- Embedded transaction history: Invoices include complete arrays of payments, refunds, and credits applied
- Integrated payment links: Payment link functionality is merged directly into the invoice model
- Comprehensive financial tracking: Track amounts paid, refunded, credited, and due in a single object
- Relationship references: Links to orders, subscriptions, and contacts for complete context
Attributes
Invoice Attributes
| Property | Type | Description |
|---|---|---|
| rootfi_id | integer | Unique identifier for this invoice |
| rootfi_created_at | string | When this invoice was created in Commenda’s system (ISO 8601) |
| rootfi_updated_at | string | When this invoice was last updated in Commenda’s system (ISO 8601) |
| rootfi_company_id | integer | Company identifier this invoice belongs to |
| platform_id | string | Platform-specific invoice identifier |
| contact_id | string | Reference to the Contact who is billed |
| currency_id | string | ISO 4217 currency code for all amounts on this invoice |
| document_number | string | Human-readable invoice number (e.g., “INV-2025-001”) |
| posted_date | string | Date when the invoice was issued (ISO 8601) |
| due_date | string | Date when payment is due (ISO 8601) |
| status | enum | Current payment status of the invoice |
| sub_total | number | Total amount before tax, discounts, and shipping |
| tax_amount | number | Total tax charged on this invoice |
| total_discount | number | Total discount amount applied |
| shipping_amount | number | Shipping and handling charges |
| total_amount | number | Final total amount due |
| amount_paid | number | Total amount paid by the contact |
| amount_refunded | number | Total amount refunded to the contact |
| amount_credited | number | Total credit notes applied to this invoice |
| amount_due | number | Remaining balance due |
| memo | string | Additional notes or description for this invoice |
| created_at | string | Original creation timestamp from platform (ISO 8601) |
| updated_at | string | Last update timestamp from platform (ISO 8601) |
| order_ids | array | References to associated Orders (for consolidated invoices) |
| subscription_id | string | Reference to the Subscription (for recurring invoices) |
| payment_link | string | URL where contact can pay this invoice online |
| payment_link_expires_at | string | Expiration date for the payment link (ISO 8601) |
| line_items | array | Individual items/services billed on this invoice |
| transactions | array | Complete history of payments, refunds, and credits |
Status Enum Values
| Value | Description |
|---|---|
draft | Invoice created but not yet sent to contact |
submitted | Invoice sent to contact, payment pending (replaces ‘open’) |
partially_paid | Partial payment received |
paid | Invoice has been fully paid |
overdue | Payment due date has passed without full payment |
void | Invoice has been cancelled/voided |
unknown | Status cannot be determined |
LineItem Attributes
| Property | Type | Description |
|---|---|---|
| rootfi_id | integer | Unique identifier for this line item |
| item_id | string | Reference to the Item/Product being billed |
| description | string | Text description of the product or service |
| quantity | integer | Number of units |
| unit_amount | number | Price per unit before tax and discounts |
| tax_amount | number | Total tax for this line item |
| discount_amount | number | Total discount applied to this line item |
| total_amount | number | Final amount (quantity × unit_amount + tax - discount) |
Expandable Attributes
Use theexpand query parameter to include related objects:
expand=contact- Includes full Contact objectexpand=line_items- Includes detailed LineItem objectsexpand=transactions- Includes all Transaction objects (payments, refunds, credits)expand=subscription- Includes the parent Subscription object (if applicable)expand=orders- Includes associated Order objects (if applicable)