Invoice Data Models

Invoice is a document issued by a seller to request payment. Here Invoice is used for both Bill and Invoice.

Invoice Info

Model ID: accounting_invoice_info

FieldTypeDescription
idString
invoiceNumberString
createdAtString
updatedAtString
typeEnum[BILL, INVOICE, NOT_SPECIFIED]
issueDateDate
dueDateDate
paidOnDateDate
totalAmountDouble
remainingAmountDouble
totalDiscountDouble
totalTaxDouble
contactIdString
companyIdString
descriptionString
currencyString
exchangeRateString
statusEnum[PAID, DUE, VOID, OVERDUE, DRAFT, SENT,OPEN,CANCELLED, NOT_SPECIFIED]

Invoice entries

Model ID: accounting_invoice_lineItems

FieldTypeDescription
lineItemslist[InvoiceLineItem]

InvoiceLineItem

FieldTypeDescription
lineItemIdString
itemIdString
itemCodeString
itemNameString
descriptionString
taxRateIdString
accountIdString
taxAmountDouble
totalAmountDouble
quantityDouble
unitRateDouble
discountAmountDouble
discountPercentageDouble
trackingCategoriesList[TrackingCategoryInfo]Please refer to TrackingCategory

Invoice Addresses

Model ID: accounting_invoice_addresses

FieldTypeDescription
addresseslist[Address]Please refer to Address Model

Invoice Payments

Model ID: accounting_invoice_payments

FieldTypeDescription
paymentslist[PaymentLineItem]

PaymentLineItem

FieldTypeDescription
idString
amountDouble
referenceNumberString
discountDouble
modeEnum[CASH , CHEQUE, ELECTRONIC_TRANSFER]
invoiceIdString
invoiceNumberString
paymentLinkedToEnum[INVOICE, BILL, NOT_SPECIFIED]

Event Data Example

{
  "info": {
    "id": "0d93e033-6548-40ea-bdfd-e551b85f5d7e",
    "invoiceNumber": "INV-101",
    "createdAt": "2024-05-20T00:00:00Z",
    "updatedAt": "2024-05-20T11:08:49Z",
    "type": "INVOICE",
    "issueDate": "2024-05-20T00:00:00Z",
    "dueDate": "2024-05-22T00:00:00Z",
    "paidOnDate": "2024-05-20T00:00:00Z",
    "totalAmount": 1100,
    "remainingAmount": 0,
    "totalDiscount": null,
    "totalTax": 100,
    "contactId": "65a3f750-de4c-463a-85b1-f04a3a37b45a",
    "companyId": "ac19c8f9-a901-4db3-bef1-5aaca2a7c15a",
    "description": null,
    "currency": null,
    "exchangeRate": null,
    "status": "PAID"
  },
  "lineItems": [
    {
      "lineItemId": "3a9701e4-5f9b-4ee7-8474-daa6d5887d6e",
      "itemId": null,
      "itemCode": "T02",
      "itemName": null,
      "description": "This is black t shirt",
      "taxRateId": "NONE",
      "accountId": "4200",
      "taxAmount": 100,
      "totalAmount": 1100,
      "quantity": 10,
      "unitRate": 120,
      "discountAmount": 100,
      "discountPercentage": 8.33,
      "trackingCategories": [
        {
          "categoryId": "2340d-cdwwr",
          "categoryName": "ASIA",
          "parentCategoryId": "a12302-2334",
          "parentCategoryName": "Region"
        }
      ]
    }
  ],
  "addresses": [
    {
      "addressLine1": "72/1A Church Street",
      "addressLine2": "Texas USA",
      "city": "Texas",
      "state": "Atlanta",
      "country": "USA",
      "zipCode": "20203939",
      "addressType": "BILLING"
    },
    {
      "addressLine1": "72/1A",
      "addressLine2": "USA",
      "city": "Texas",
      "state": "Atlanta",
      "country": "USA",
      "zipCode": "20203939",
      "addressType": "SHIPPING"
    }
  ],
  "payments": [
    {
      "id": "eeedd617-d2c4-4d8c-96f9-69eeeb62b1e6",
      "amount": 1100,
      "referenceNumber": null,
      "discount": null,
      "mode": "CASH",
      "paymentLinkedTo": "INVOICE",
      "invoiceId": "0d93e033-6548-40ea-bdfd-e551b85f5d7e",
      "invoiceNumber": "INV-101"
    }
  ]
}