Accounts Data Models

Account is used by companies to track transactions. It can be bank account or general ledger account.

How to get the list of Accounts

There are two ways to fetch the list of accounts from your integrations:

1. Syncs (Webhook-based Bulk Reads)

Syncs provide an automated, push-based approach for bulk data retrieval. Once you set up a sync for an integration, Knit polls the source app for changes and sends updates straight to your webhook. This webhook-based model eliminates the need for you to continuously pull data.

Read more about syncs and webhooks here: https://developers.getknit.dev/docs/register-webhook-url#/

2. Read APIs (On-demand Individual Reads)

Read APIs provide on-demand access to specific data through request-response calls. These are standard GET/List operations that allow you to retrieve account information whenever needed.

You can refer to accounting APIs here: https://developers.getknit.dev/reference/list-accounts#/

Data Model

Model IDEvent KeyDescription
accounting_accounts_infoinfo

Accounts Info

Model ID: accounting_accounts_info

Field Type Description

id

String

name

String

category

Enum

[BANK_ACCOUNT, LEDGER_ACCOUNT, NOT_SPECIFIED]

type

Enum

[ASSET, EQUITY, EXPENSE, LIBALITY, REVENUE, NOT_SPECIFIED]

description

String

accountNumber

String

status

Enum

[ACTIVE, INACTIVE, PENDING, NOT_SPECIFIED]

currentBalance

Double

companyId

String

linkedCompanyIds

List[String]

List of company Ids associated with object. (Applicable for multi subsidiary apps like Netsuite.)

currency

String

One of among Currency Codes (ISO 4217) for example -
INR,
USD,
EUR

parentAccountId

String

createdAt

Date

updatedAt

Date


Event Data Example

{
  "info": {
    "id": "bca61aa6-3ac1-4ae9-bd34-46c7f9a26d87",
    "name": "Accounts Receivable",
    "category": "LEDGER_ACCOUNT",
    "type": "ASSET",
    "description": "Outstanding invoices the company has issued out to the client but has not yet received in cash at balance date.",
    "accountNumber": "2920023748",
    "status": "ACTIVE",
    "currentBalance": 3000,
    "companyId": "ac19c8f9-a901-4db3-bef1-5aaca2a7c15a",
    "currency": "USD",
    "parentAccountId": "5aaca2a7c15a-46c7f9a26d87",
    "createdAt": "2024-05-09T06:04:00Z",
    "updatedAt": "2024-05-09T06:04:00Z"
  }
}