# Create a bank account Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-bank-account /openapi_v4_core.json post /v4/core/companies/{companyId}/bank_accounts # Create a bank transaction Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-bank-transaction /openapi_v4_core.json post /v4/core/companies/{companyId}/bank_transactions # Create a bill credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-bill-credit-note /openapi_v4_core.json post /v4/core/companies/{companyId}/bill_credit_notes # Create a bill payment Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-bill-payment /openapi_v4_core.json post /v4/core/companies/{companyId}/bill_payments # Create an account Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-account /openapi_v4_core.json post /v4/core/companies/{companyId}/accounts # Get a balance sheet Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-balance-sheet /openapi_v4_core.json get /v4/core/companies/{companyId}/balance_sheets/{id} # Get a bank account Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-bank-account /openapi_v4_core.json get /v4/core/companies/{companyId}/bank_accounts/{id} # Get a bank transaction Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-bank-transaction /openapi_v4_core.json get /v4/core/companies/{companyId}/bank_transactions/{id} # Get a bill credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-bill-credit-note /openapi_v4_core.json get /v4/core/companies/{companyId}/bill_credit_notes/{id} # Get a bill payment Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-bill-payment /openapi_v4_core.json get /v4/core/companies/{companyId}/bill_payments/{id} # Get an account Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-account /openapi_v4_core.json get /v4/core/companies/{companyId}/accounts/{id} # List accounts Source: https://integrations.docs.commenda.io/api-reference/accounting/list-accounts /openapi_v4_core.json get /v4/core/companies/{companyId}/accounts # List balance sheets Source: https://integrations.docs.commenda.io/api-reference/accounting/list-balance-sheets /openapi_v4_core.json get /v4/core/companies/{companyId}/balance_sheets # List bank accounts Source: https://integrations.docs.commenda.io/api-reference/accounting/list-bank-accounts /openapi_v4_core.json get /v4/core/companies/{companyId}/bank_accounts # List bank transactions Source: https://integrations.docs.commenda.io/api-reference/accounting/list-bank-transactions /openapi_v4_core.json get /v4/core/companies/{companyId}/bank_transactions # List bill credit notes Source: https://integrations.docs.commenda.io/api-reference/accounting/list-bill-credit-notes /openapi_v4_core.json get /v4/core/companies/{companyId}/bill_credit_notes # List bill payments Source: https://integrations.docs.commenda.io/api-reference/accounting/list-bill-payments /openapi_v4_core.json get /v4/core/companies/{companyId}/bill_payments # List bills Source: https://integrations.docs.commenda.io/api-reference/accounting/list-bills /openapi_v4_core.json get /v4/core/companies/{companyId}/bills # Update a bank account Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-bank-account /openapi_v4_core.json put /v4/core/companies/{companyId}/bank_accounts # Update a bank transaction Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-bank-transaction /openapi_v4_core.json put /v4/core/companies/{companyId}/bank_transactions # Update a bill credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-bill-credit-note /openapi_v4_core.json put /v4/core/companies/{companyId}/bill_credit_notes # Update a bill payment Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-bill-payment /openapi_v4_core.json put /v4/core/companies/{companyId}/bill_payments # Update an account Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-account /openapi_v4_core.json put /v4/core/companies/{companyId}/accounts # Get Source: https://integrations.docs.commenda.io/api-reference/apilog/get /openapi_v4_core.json get /v4/core/api-log/{logId} # List Source: https://integrations.docs.commenda.io/api-reference/apilog/list /openapi_v4_core.json get /v4/core/api-log # Archive Source: https://integrations.docs.commenda.io/api-reference/companies/archive /openapi_v4_core.json delete /v4/core/companies/{companyId} # Disconnect integration Source: https://integrations.docs.commenda.io/api-reference/companies/disconnect-integration /openapi_v4_core.json put /v4/core/companies/{companyId}/disconnect # Get Source: https://integrations.docs.commenda.io/api-reference/companies/get /openapi_v4_core.json get /v4/core/companies/{companyId} # List Source: https://integrations.docs.commenda.io/api-reference/companies/list /openapi_v4_core.json get /v4/core/companies Returns a cursor-paginated list of the organisation's companies. # Reset a data model's sync config Source: https://integrations.docs.commenda.io/api-reference/companies/reset-a-data-models-sync-config /openapi_v4_core.json post /v4/core/companies/{companyId}/sync-config/reset/{dataModel} # Reset sync config Source: https://integrations.docs.commenda.io/api-reference/companies/reset-sync-config /openapi_v4_core.json post /v4/core/companies/{companyId}/sync-config/reset # Update Source: https://integrations.docs.commenda.io/api-reference/companies/update /openapi_v4_core.json patch /v4/core/companies/{companyId} # Update sync config Source: https://integrations.docs.commenda.io/api-reference/companies/update-sync-config /openapi_v4_core.json patch /v4/core/companies/{companyId}/sync-config # List Source: https://integrations.docs.commenda.io/api-reference/disconnectrequest/list /openapi_v4_core.json get /v4/core/disconnect-requests # Resolve Source: https://integrations.docs.commenda.io/api-reference/disconnectrequest/resolve /openapi_v4_core.json patch /v4/core/disconnect-requests/{id} # Get Source: https://integrations.docs.commenda.io/api-reference/integration/get /openapi_v4_core.json get /v4/core/integrations/{integrationType} # Get webhook setup Source: https://integrations.docs.commenda.io/api-reference/integration/get-webhook-setup /openapi_v4_core.json get /v4/core/integrations/{integrationType}/webhook-setup # List Source: https://integrations.docs.commenda.io/api-reference/integration/list /openapi_v4_core.json get /v4/core/integrations # List webhook topics Source: https://integrations.docs.commenda.io/api-reference/integration/list-webhook-topics /openapi_v4_core.json get /v4/core/integrations/{integrationType}/webhook-topics # Save settings Source: https://integrations.docs.commenda.io/api-reference/integration/save-settings /openapi_v4_core.json post /v4/core/integrations # Create Source: https://integrations.docs.commenda.io/api-reference/invite-links/create /openapi_v4_core.json post /v4/core/invite-links Creates an invite link a customer uses to connect their integration. # Delete Source: https://integrations.docs.commenda.io/api-reference/invite-links/delete /openapi_v4_core.json delete /v4/core/invite-links/{id} # Get Source: https://integrations.docs.commenda.io/api-reference/invite-links/get /openapi_v4_core.json get /v4/core/invite-links/{inviteLinkUuid} # List Source: https://integrations.docs.commenda.io/api-reference/invite-links/list /openapi_v4_core.json get /v4/core/invite-links # Update Source: https://integrations.docs.commenda.io/api-reference/invite-links/update /openapi_v4_core.json patch /v4/core/invite-links/{inviteLinkUuid} # List Source: https://integrations.docs.commenda.io/api-reference/job/list /openapi_v4_core.json get /v4/core/syncs/{syncId}/jobs # Invite Source: https://integrations.docs.commenda.io/api-reference/member/invite /openapi_v4_core.json post /v4/core/members/invite # List Source: https://integrations.docs.commenda.io/api-reference/member/list /openapi_v4_core.json get /v4/core/members # Remove Source: https://integrations.docs.commenda.io/api-reference/member/remove /openapi_v4_core.json delete /v4/core/members/{memberId} # Get sync config Source: https://integrations.docs.commenda.io/api-reference/organization/get-sync-config /openapi_v4_core.json get /v4/core/organizations/sync-config # Update sync config Source: https://integrations.docs.commenda.io/api-reference/organization/update-sync-config /openapi_v4_core.json post /v4/core/organizations/sync-config # Make a request Source: https://integrations.docs.commenda.io/api-reference/passthrough/make-a-request /openapi_v4_core.json post /v4/core/passthrough # Get Source: https://integrations.docs.commenda.io/api-reference/stats/get /openapi_v4_core.json get /v4/core/stats # Cancel Source: https://integrations.docs.commenda.io/api-reference/syncaction/cancel /openapi_v4_core.json post /v4/core/syncs/{syncId}/cancel # Retry Source: https://integrations.docs.commenda.io/api-reference/syncaction/retry /openapi_v4_core.json post /v4/core/syncs/{syncId}/retry # List Source: https://integrations.docs.commenda.io/api-reference/syncs/list /openapi_v4_core.json get /v4/core/companies/{companyId}/syncs # Trigger Source: https://integrations.docs.commenda.io/api-reference/syncs/trigger /openapi_v4_core.json post /v4/core/companies/{companyId}/syncs Starts a sync for the company's active connection. # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/overview/environments Learn how to use the Commenda Integrations API The Commenda Integrations API is a single, unified interface to your customers' accounting, payments, e-commerce, and CRM platforms. Connect a company to a source platform once, then read (and, where supported, write) standardized data models that look the same no matter which platform they came from, so you build your integration once instead of per platform. ## Environments | Environment | Base URL | | - | - | | Production | `https://api.integrations.commenda.io` | All routes are under the `/v4` prefix (e.g. `https://api.integrations.commenda.io/v4/core/companies`). ## Authentication Every request is authenticated with an API key sent in the `api_key` header. ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies" \ -H "api_key: YOUR_API_KEY" ``` Generate and manage API keys in the [Commenda dashboard](https://integrations.commenda.io/settings/api-keys). ## Data model routes Unified data models are read (and written, where supported) under a company: ``` GET /v4/core/companies/{companyId}/{data_model} GET /v4/core/companies/{companyId}/{data_model}/{id} ``` List endpoints support per-field filters using operator keys, cursor pagination (`limit`, `next`), and `expand` for related objects: ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies/{companyId}/invoices?status[eq]=PAID&limit=50&expand=line_items" \ -H "api_key: YOUR_API_KEY" ``` ## Callback URL OAuth2 integrations redirect to: ``` https://sdk.integrations.commenda.io/oauth/callback ``` ## Migrating from V3 V4 is a redesigned API and is not backward-compatible with V3 at the route or response level. See **[Migrating from V3 to V4](/api-reference/v4/overview/migrating-from-v3)** for what changes and how to move over. ## Support * **Documentation:** [integrations.docs.commenda.io](https://integrations.docs.commenda.io) * **Support:** [support@commenda.io](mailto:support@commenda.io) # Migrating from V3 to V4 Source: https://integrations.docs.commenda.io/api-reference/v4/overview/migrating-from-v3 What changes between the V3 and V4 Integrations APIs, and how to move your integration over. V4 is a redesigned API and is not backward-compatible with V3 at the route or response level. The good news: the fundamentals are unchanged. You authenticate the same way, and individual records keep the same field-level shape. Most of the work is updating your base URL and route paths, and adjusting to the wrapped response envelope. ## How the migration works Your connections are migrated for you by the Commenda team. You do not re-run OAuth or reconnect your customers as part of the move. * **Connections are copied as-is.** Each connection carries over with the same status it had in V3. The migration does not change a connection's state or trigger a re-authentication. * **Your code is what changes.** Point your integration at the V4 base URL and routes (below). Once you cut over, V4 becomes the source of truth for that organization. > [!NOTE] > > Connections for platforms that V4 does not yet support are still copied over, but they are inert: they will not appear in the [Commenda Integrations Dashboard](https://integrations.commenda.io/) and will not sync, either automatically or manually. Support is added over time, and they begin syncing once V4 supports the platform. To schedule a migration, reach out to [support@commenda.io](mailto:support@commenda.io). ## What changes at a glance | | V3 | V4 | | - | - | - | | Base URL | `https://api.rootfi.dev/v3` | `https://api.integrations.commenda.io/v4` | | Regions | Separate regional endpoints | Single base URL for all regions | | Authentication | `api_key` header | `api_key` header (unchanged) | | Route shape | `/{category}/{model}` | `/v4/core/companies/{companyId}/{model}` | | Response envelope | `{ data: [...], prev, next, total_count }` | `{ data: [...], pagination: { prev, next, total_count }, request_id }` | | Record identifier | `rootfi_id` | `rootfi_id` (values are reassigned) | | Dashboard | `integrate.rootfi.dev` | `integrations.commenda.io` | | SDK | Legacy RootFi SDK | [`@commenda-integrations/api`](/api-reference/v4/sdk/nodejs) | ## Authentication is unchanged Requests are still authenticated with an API key in the `api_key` header. Generate keys in the [Commenda Integrations Dashboard](https://integrations.commenda.io/settings/api-keys). ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies" \ -H "api_key: YOUR_API_KEY" ``` ## Update your API calls **1. Switch the base URL** Replace the V3 host with `https://api.integrations.commenda.io`. All routes live under the `/v4` prefix. V4 serves every region from this single base URL, so any regional endpoints you used in V3 collapse into this one. **2. Scope routes to a company** V3 routes were category-scoped (`/accounting/invoices`). V4 routes are scoped to a company and drop the category prefix. ``` V3 GET https://api.rootfi.dev/v3/accounting/invoices V4 GET https://api.integrations.commenda.io/v4/core/companies/{companyId}/invoices ``` **3. Update filtering and pagination** V4 filters using operator keys (`eq`, `in`, `gte`, `lte`) on each model's filterable fields, paginates with `limit` and a `next` cursor, and expands related objects with `expand`. See [Reading Data](/documentation/concepts/reading-data). ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies/{companyId}/invoices?status[eq]=PAID&limit=50&expand=line_items" \ -H "api_key: YOUR_API_KEY" ``` Pass the `next` cursor back as the `next` query parameter to page forward. **4. Adjust to the wrapped response envelope** V4 wraps every response in `{ data, request_id }`. For list reads, the records stay at `data` and the cursor metadata moves into a `pagination` sibling. ``` V3 response.data // the records array response.next // pagination cursor V4 response.data // the records array response.pagination.next // pagination cursor (also prev, total_count) response.request_id // per-request identifier ``` ## Record IDs and the stable join key V4 re-syncs your data into its own storage, so `rootfi_id` values are **not** the same as they were in V3. If you stored `rootfi_id`s to reference records, you will need to re-map them after cutover. The identifier that is stable across both versions is `platform_id`, the record's ID on the source platform. Join on `platform_id` to reconcile V3 records with their V4 equivalents. ## Choose your initial sync window When your organization moves to V4, its first sync backfills a historical window rather than the platform's entire history. Pick a window based on how much history you need. > [!NOTE] > > We suggest the **last 30 days** up to the **last quarter**, and no longer than that. A larger window means a slower first sync with limited added value for most integrations. If you later need data older than your chosen window, request a full sync from [support@commenda.io](mailto:support@commenda.io). ## Webhooks Your webhook endpoints carry over during the migration, but the payloads do not. Update your handlers before cutting over. **The envelope changed.** V3 sent flat bodies with a `webhook_type` discriminator and top-level `rootfi_id`, `created_at`, and `company_id`. V4 nests everything under `data` and names the discriminator `event`: ``` V3 { "webhook_type": "SYNC_COMPLETED", "company_id": 1234, "data": {...} } V4 { "event": "SYNC_COMPLETED", "data": { "company_id": 1234, ... } } ``` **Two event types are new:** `SYNC_STARTED` and `DISCONNECT_REQUESTED`. The latter reports that an end user has *asked* you to disconnect — it does not disconnect anything itself. **Field renames on the events that carry over:** | Event | V3 | V4 | | - | - | - | | `DATA_MODEL_CHANGES` | records under `data` | records under `records` | | `DATA_MODEL_CHANGES` | `data_model` plural (`INVOICES`) | singular (`INVOICE`) | | `CONNECTION_CHANGED` | `connection_status` | `status` | | `CONNECTION_CHANGED` | — | `connection_id`, the composite `{company_id}_{integration_type}` | **Signing is new.** V3 did not sign outbound webhooks — authenticity relied on a static token in a custom header. V4 signs every delivery with an HMAC in `X-RootFi-Signature` when the config has a signing key, so you can verify authenticity properly. Custom headers still work. See [Webhooks](/documentation/concepts/webhooks) for the current payloads, signature verification, and setup. ## SDK If you used the legacy RootFi SDK, switch to [`@commenda-integrations/api`](/api-reference/v4/sdk/nodejs), which is generated from the V4 OpenAPI spec and typed end to end. ## Migration checklist * [ ] Base URL switched to `https://api.integrations.commenda.io/v4`. * [ ] Routes scoped to `{companyId}` and category prefixes removed. * [ ] Filtering and pagination updated to operator keys, `limit`, and the `next` cursor. * [ ] Response parsing updated for the wrapped envelope (records at `data`, cursors under `pagination`, `request_id` present). * [ ] Stored `rootfi_id`s re-mapped, or lookups switched to `platform_id`. * [ ] Initial sync window chosen and confirmed with Commenda. * [ ] Webhook consumers verified against the V4 payloads. ## Support * **Documentation:** [integrations.docs.commenda.io](https://integrations.docs.commenda.io) * **Support:** [support@commenda.io](mailto:support@commenda.io) # TypeScript SDK Source: https://integrations.docs.commenda.io/api-reference/v4/sdk/nodejs Install the Commenda Integrations TypeScript SDK for the V4 API. The official TypeScript SDK for the Commenda Integrations V4 API is [`@commenda-integrations/api`](https://www.npmjs.com/package/@commenda-integrations/api). ## Installation ```bash theme={null} npm i @commenda-integrations/api ``` Import the client: ```ts theme={null} import { CommendaIntegrations } from "@commenda-integrations/api"; ``` ## Instantiate the client Instantiate with your API key (generate keys in the [Commenda dashboard](https://integrations.commenda.io/settings/api-keys)). It targets production by default; pass `baseUrl` to point elsewhere for local development. ```ts theme={null} const commenda = new CommendaIntegrations({ apiKey: process.env.COMMENDA_API_KEY! }); ``` Resources are namespaced: **`commenda.core.*`** for platform & management endpoints, and **`commenda.dataModels.*`** for the unified data models. ## Run your first request ### Core API ```ts theme={null} // Create an invite link a customer uses to connect their integration const { data: inviteLink } = await commenda.core.inviteLinks.create({ integration: "NETSUITE", companyName: "Test Company", }); // List the organisation's companies const { data: companies } = await commenda.core.companies.list(); ``` ### Unified API ```ts theme={null} // List a company's invoices, filtered const { data: invoices } = await commenda.dataModels.invoices.list(companyId, { "status[eq]": "PAID", "posted_date[gte]": "2024-01-01", limit: 50, }); // Get one record const invoice = await commenda.dataModels.invoices.get(companyId, invoiceId); // Create (proxied to the connected platform) await commenda.dataModels.invoices.create(companyId, { data: { /* fields */ } }); ``` Iterate every page with the `paginate` helper: ```ts theme={null} import { paginate } from "@commenda-integrations/api"; for await (const invoice of paginate(next => commenda.dataModels.invoices.list(companyId, { limit: 100, next }))) { // ... } ``` ## Error handling Non-2xx responses throw a `CommendaApiError`: ```ts theme={null} import { CommendaApiError } from "@commenda-integrations/api"; try { await commenda.dataModels.invoices.get(companyId, invoiceId); } catch (err) { if (err instanceof CommendaApiError) { console.error(err.statusCode, err.message, err.errorCode, err.requestId); } } ``` # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/accounts/overview An account contained within the business entity's chart of accounts. The Accounts Data Model represents a record in an accounting system that tracks the financial activities of a specific asset, liability, equity, revenue, or expense. These records increase and decrease as transactions occur throughout the accounting period. The aggregation of each Account object is often referred to as the Chart of Accounts. * **Unified account properties**: Essential account details like name, description, currency, and current balance are standardized across different accounting platforms * **Hierarchical structure**: Accounts can be linked to parent accounts using the `parent_account_id`, enabling the representation of complex account structures and relationships * **Categorisation and status**: The model supports account categorisation with main categories (asset, liability, equity, revenue, or expense) and subcategories, as well as tracking account status for better organisation and reporting ## Attributes ### Accounts Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this account | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this account in the source accounting platform | | `nominal_code` | string | The nominal code of the account | | `name` | string | The name of the account | | `description` | string | The description of the account | | `currency_id` | enum | ISO 4217 currency code | | `current_balance` | double | The current balance of the account | | `status` | enum | The status of the account | | `category` | enum | The category of the account | | `sub_category` | string | The sub category of the account | | `parent_account_id` | string | The parent account ID of the account | | `updated_at` | string | The date and time the account was last updated | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Account is active and in use | | `ARCHIVED` | Account has been archived | | `UNKNOWN` | Status cannot be determined from the platform | ### Category Enum Values | Value | Description | | - | - | | `ASSET` | Account represents an asset (e.g., cash, inventory, property) | | `EXPENSE` | Account represents an expense | | `LIABILITY` | Account represents a liability (e.g., loans, accounts payable) | | `EQUITY` | Account represents equity (e.g., retained earnings, capital) | | `INCOME` | Account represents income or revenue | | `BANK` | Account represents a bank account | | `UNKNOWN` | Category cannot be determined from the platform | ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this account in the source accounting platform | | `nominal_code` | string | The nominal code of the account | | `name` | string | The name of the account | | `description` | string | The description of the account | | `currency_id` | enum | ISO 4217 currency code | | `current_balance` | double | The current balance of the account | | `status` | enum | The status of the account | | `category` | enum | The category of the account | | `sub_category` | string | The sub category of the account | | `parent_account_id` | string | The parent account ID of the account | | `updated_at` | string | The date and time the account was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/balance_sheets/overview A financial report that shows a business's assets, liabilities, and equity at a specific point in time. In an accounting platform, a balance sheet is typically generated automatically based on the financial transactions that have been recorded in the system. The Balance Sheet Data Model represents a financial report that shows a business's assets, liabilities, and equity at a specific point in time. In an accounting platform, a balance sheet is typically generated automatically based on the financial transactions that have been recorded in the system. * **Unified balance sheet properties**: Essential balance sheet details, such as period dates, net assets, and line items, are standardized across different accounting platforms * **Hierarchical line item structure**: The model supports nested line items for assets, liabilities, and equity, enabling detailed breakdowns of financial positions * **Automatic generation**: Balance sheets are typically generated automatically based on recorded financial transactions ## Attributes ### Balance Sheets Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this balance sheet | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this balance sheet in the source accounting platform | | `assets` | object | The line items for assets of the balance sheet report | | `liabilities` | object | The line items for liabilities of the balance sheet report | | `equity` | object | The line items for equity of the balance sheet report | | `net_assets` | double | The net assets of the balance sheet report | | `currency_id` | enum | | | `period_start` | string | The start date of the balance sheet report period | | `period_end` | string | The end date of the balance sheet report period | | `updated_at` | string | The date and time the balance sheet was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/bank-accounts/overview A Bank Account represents the financial accounts maintained by the business entity at various banking institutions, capturing account-specific details. **The Bank Accounts Data Model** represents the financial accounts maintained by the business entity at various banking institutions. This unified model streamlines access to bank account information across various accounting platforms. * **Unified bank account properties**: Essential bank account details such as institution name, account name, balance, and currency are standardized across different accounting platforms * **Currency support**: The model includes the ISO-4217 currency code for each bank account, enabling seamless handling of international transactions and reporting ## Attributes ### Bank Accounts Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this bank account | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this bank account in the source accounting platform | | `institution_name` | string | The name of the financial institution for the bank account | | `account_name` | string | The name of the bank account | | `account_number` | string | The bank account number | | `balance` | double | The current balance of the bank account | | `currency_id` | enum | ISO 4217 currency code | | `category` | string | The category of the bank account | | `updated_at` | string | The date and time the bank account was last updated | ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this bank account in the source accounting platform | | `institution_name` | string | The name of the financial institution for the bank account | | `account_name` | string | The name of the bank account | | `account_number` | string | The bank account number | | `balance` | double | The current balance of the bank account | | `currency_id` | enum | ISO 4217 currency code | | `category` | string | The category of the bank account | | `updated_at` | string | The date and time the bank account was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/bank_transactions/overview Bank Transactions include the Transactional banking data for a specific company and account. **The Bank Transactions Data Model** represents transactional banking data for a specific company and account. This unified model simplifies the management and retrieval of transaction information across different accounting platforms. * **Unified transaction properties**: Essential transaction details such as transaction date, amount, type, and status are standardized across different accounting platforms * **Linked account and customer data**: Transactions are associated with specific accounts and customers through the `account_id` and `contact_id` properties, facilitating easier tracking and reporting * **Currency support and exchange rates**: The data model includes the transaction currency and exchange rate, enabling accurate representation of multi-currency transactions and conversions ## Attributes ### Bank Transactions Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this bank transaction | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this bank transaction in the source accounting platform | | `contact_id` | string | The contact ID of the bank transaction | | `account_id` | string | The account ID of the bank transaction | | `from_account_id` | string | The from account ID of the bank transaction | | `to_account_id` | string | The to account ID of the bank transaction | | `currency_id` | enum | ISO 4217 currency code | | `amount` | double | The total amount of the bank transaction | | `type` | string | The type of the bank transaction | | `debit_or_credit` | enum | The type of transaction | | `status` | string | The status of the bank transaction | | `currency_rate` | double | The currency rate of the bank transaction | | `transaction_date` | string | The transaction date of the bank transaction | | `updated_at` | string | The date and time the bank transaction was last updated | ### Debit Or Credit Enum Values | Value | Description | | - | - | | `CREDIT` | Transaction is a credit entry | | `DEBIT` | Transaction is a debit entry | | `UNKNOWN` | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=contact` — includes the related Contact object(s). * `expand=bank_account` — includes the related Bank Account object(s). * `expand=currency` — includes the related Currency object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this bank transaction in the source accounting platform | | `contact_id` | string | The contact ID of the bank transaction | | `account_id` | string | The account ID of the bank transaction | | `from_account_id` | string | The from account ID of the bank transaction | | `to_account_id` | string | The to account ID of the bank transaction | | `currency_id` | enum | ISO 4217 currency code | | `amount` | double | The total amount of the bank transaction | | `type` | string | The type of the bank transaction | | `debit_or_credit` | enum | The type of transaction | | `status` | string | The status of the bank transaction | | `currency_rate` | double | The currency rate of the bank transaction | | `transaction_date` | string | The transaction date of the bank transaction | | `updated_at` | string | The date and time the bank transaction was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/bill_credit_notes/overview A Bill Credit Note is a financial transaction representing a reduction that can be applied against one or multiple bills issued to Vendors. **The Bill Credit Notes Data Model** represents a financial transaction that can be applied against one or multiple bills issued to vendors. This unified model standardizes and simplifies the management of credit note information across various accounting platforms. * **Unified credit note properties**: Essential credit note details, such as contact ID, document number, total amount, and currency, are standardized across different accounting platforms * **Detailed status tracking**: The model supports various credit note statuses, including draft, submitted, partially paid, paid, overdue, void, and unknown, for better organisation and reporting * **Line item integration**: Credit notes can include an array of associated line items, ensuring comprehensive representation of credit note details and relationships to other data models ## Attributes ### Bill Credit Notes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this bill credit note | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this bill credit note in the source accounting platform | | `contact_id` | string | The contact ID of the bill credit note | | `document_number` | string | The document number of the bill credit note | | `total_amount` | double | The total amount of the bill credit note | | `remaining_credit` | double | The remaining credit amount of the bill credit note | | `posted_date` | string | The posted date of the bill credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the bill credit note | | `status` | enum | The status of the bill credit note | | `bill_ids` | array | The bill IDs associated with the bill credit note | | `updated_at` | string | The date and time the bill credit note was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Bill credit note is in draft status and has not been finalized | | `SUBMITTED` | Bill credit note has been submitted but not yet paid | | `PARTIALLY_PAID` | Bill credit note has received partial payment | | `PAID` | Bill credit note has been fully paid | | `OVERDUE` | Bill credit note has passed its due date without payment | | `VOID` | Bill credit note has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this bill credit note in the source accounting platform | | `contact_id` | string | The contact ID of the bill credit note | | `document_number` | string | The document number of the bill credit note | | `total_amount` | double | The total amount of the bill credit note | | `remaining_credit` | double | The remaining credit amount of the bill credit note | | `posted_date` | string | The posted date of the bill credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the bill credit note | | `status` | enum | The status of the bill credit note | | `bill_ids` | array | The bill IDs associated with the bill credit note | | `updated_at` | string | The date and time the bill credit note was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/bill_payments/overview The Bill Payments Data Model is designed to standardise and simplify the management of bill payment information across various accounting platforms. The Bill Payments Data Model represents payments made against bills. This unified model standardizes and simplifies the management of bill payment information across various accounting platforms. * **Unified bill payment properties**: Essential core payment details, such as payment date, payment mode, currency, and amount, are standardized across different accounting platforms * **Associated data linkage**: The data model connects bill payments to related information, such as bills, contacts, and accounts, using platform-specific IDs for easy cross-referencing * **Currency conversion support**: The `currency_rate` property provides the exchange rate between the payment currency and the base currency, facilitating multi-currency payment handling and reporting ## Attributes ### Bill Payments Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this bill payment | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this bill payment in the source accounting platform | | `bill_id` | string | The bill ID of the bill payment | | `payment_id` | string | The payment ID of the bill payment | | `credit_note_id` | string | The credit note ID associated with the bill payment (if paying via debit note) | | `amount` | double | The total amount of the bill payment | | `payment_mode` | string | The payment mode of the bill payment | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the bill payment | | `memo` | string | The memo or notes of the bill payment | | `payment_date` | string | The payment date of the bill payment | | `account_id` | string | The account ID of the bill payment | | `contact_id` | string | The contact ID of the bill payment | | `document_number` | string | The document number of the bill payment | | `updated_at` | string | The date and time the bill payment was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=bill` — includes the related Bill object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=account` — includes the related Account object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this bill payment in the source accounting platform | | `bill_id` | string | The bill ID of the bill payment | | `payment_id` | string | The payment ID of the bill payment | | `credit_note_id` | string | The credit note ID associated with the bill payment (if paying via debit note) | | `amount` | double | The total amount of the bill payment | | `payment_mode` | string | The payment mode of the bill payment | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the bill payment | | `memo` | string | The memo or notes of the bill payment | | `payment_date` | string | The payment date of the bill payment | | `account_id` | string | The account ID of the bill payment | | `contact_id` | string | The contact ID of the bill payment | | `document_number` | string | The document number of the bill payment | | `updated_at` | string | The date and time the bill payment was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/bills/overview A record of goods or services purchased from a vendor. The Bills Data Model represents a record of goods or services purchased from a vendor. This unified model simplifies handling bill-related information across various accounting platforms. * **Unified bill properties**: Essential bill information such as vendor, account, dates, currency, and amounts are standardized across different accounting platforms * **Status tracking**: The model supports tracking the status of a bill, including draft, submitted, partially paid, paid, overdue, void, or unknown, for better bill management and reporting * **Relationship with other data models**: The model allows for the inclusion of associated line items, bill payments, and purchase orders, providing a complete picture of each bill * **Currency conversion**: The `currency_rate` property allows for easy currency conversion between the payment currency and the base currency, ensuring accurate financial reporting and analysis ## Attributes ### Bills Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this bill | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this bill in the source accounting platform | | `document_number` | string | The document number of the bill | | `posted_date` | string | The posted date of the bill | | `due_date` | string | The due date of the bill | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the bill | | `sub_total` | double | The sub total of the bill | | `tax_amount` | double | The tax amount of the bill | | `total_discount` | double | The total discount of the bill | | `total_amount` | double | The total amount of the bill | | `amount_due` | double | The amount due of the bill | | `status` | enum | The status of the bill | | `contact_id` | string | The contact ID of the bill | | `memo` | string | The memo or notes of the bill | | `purchase_order_ids` | array | The purchase order IDs associated with the bill | | `updated_at` | string | The date and time the bill was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Bill is in draft status and has not been finalized | | `SUBMITTED` | Bill has been submitted but not yet paid | | `PARTIALLY_PAID` | Bill has received partial payment | | `PAID` | Bill has been fully paid | | `OVERDUE` | Bill has passed its due date without payment | | `VOID` | Bill has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=documents` — includes the related Documents object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=bill_payments` — includes the related Bill Payments object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this bill in the source accounting platform | | `document_number` | string | The document number of the bill | | `posted_date` | string | The posted date of the bill | | `due_date` | string | The due date of the bill | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the bill | | `sub_total` | double | The sub total of the bill | | `tax_amount` | double | The tax amount of the bill | | `total_discount` | double | The total discount of the bill | | `total_amount` | double | The total amount of the bill | | `amount_due` | double | The amount due of the bill | | `status` | enum | The status of the bill | | `contact_id` | string | The contact ID of the bill | | `memo` | string | The memo or notes of the bill | | `purchase_order_ids` | array | The purchase order IDs associated with the bill | | `updated_at` | string | The date and time the bill was last updated | # Create Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/create /openapi_v4_core.json post /v4/core/webhook-config # Delete Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/delete /openapi_v4_core.json delete /v4/core/webhook-config/{webhookConfigId} # Get Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/get /openapi_v4_core.json get /v4/core/webhook-config/{webhookConfigId} # List Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/list /openapi_v4_core.json get /v4/core/webhook-config # List platform topics Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/list-platform-topics /openapi_v4_core.json get /v4/core/webhook-config/platform-topics # Update Source: https://integrations.docs.commenda.io/api-reference/webhookconfig/update /openapi_v4_core.json put /v4/core/webhook-config/{webhookConfigId} # Create Source: https://integrations.docs.commenda.io/api-reference/webhookcredential/create /openapi_v4_core.json post /v4/core/webhook-credential # Delete Source: https://integrations.docs.commenda.io/api-reference/webhookcredential/delete /openapi_v4_core.json delete /v4/core/webhook-credential/{webhookCredentialId} # Get Source: https://integrations.docs.commenda.io/api-reference/webhookcredential/get /openapi_v4_core.json get /v4/core/webhook-credential/{webhookCredentialId} # List Source: https://integrations.docs.commenda.io/api-reference/webhookcredential/list /openapi_v4_core.json get /v4/core/webhook-credential # Update Source: https://integrations.docs.commenda.io/api-reference/webhookcredential/update /openapi_v4_core.json put /v4/core/webhook-credential/{webhookCredentialId} # Get Source: https://integrations.docs.commenda.io/api-reference/webhooklog/get /openapi_v4_core.json get /v4/core/webhook-logs/{deliveryId} # List Source: https://integrations.docs.commenda.io/api-reference/webhooklog/list /openapi_v4_core.json get /v4/core/webhook-logs # Data Storage Source: https://integrations.docs.commenda.io/documentation/concepts/data-storage Learn how RootFi stores, manages, and deletes your customers data. ## How we store data RootFi mirrors the data in the underlying platform and syncs the data into our database at regular intervals. When you call our APIs you are querying our database allowing you to fetch the required data points quickly and reliably. By default we unify and cache all synced data. Related records are linked by their primary keys, so you can pull nested objects together with the `expand` query parameter — see [Reading Data](/documentation/concepts/reading-data). When you delete a company on RootFi, we delete all the associated data from our database. > [!NOTE] > > **Privacy and Security** > > We take the privacy and security of your data seriously. Contact [support@commenda.io](mailto:support@commenda.io) for our current security and compliance posture. ## Secure Sync (Enterprise Only) If you do not want RootFi to cache the sync data for regulatory concerns or otherwise, you have the option. Using Secure Sync, you can use RootFi's syncing infrastructure to sync data from any integration platform while maintaining full control over the data. We will not store any of the incoming data and instead directly pass it on to you via our webhooks. The only data we can access would be the access and refresh tokens needed to communicate with the integration platforms. We securely encrypt all authentication information for all our integrations. **Make sure to enable a Data Model changes webhook so that you can receive all the synced data** # Error Handling Source: https://integrations.docs.commenda.io/documentation/concepts/error-handling How errors surface when syncing and writing data, and what the error codes mean. ## Reading data When a sync reads from an integration and hits an unexpected error, the affected data model is marked **FAILED**. Subscribe to the [`SYNC_COMPLETED` webhook](/documentation/concepts/webhooks#sync-completed) to be notified when a sync finishes and inspect which data models succeeded — the payload carries `status` along with per-job counts. ## Writing data Write failures return an error response in this shape: ```json theme={null} { "error": { "code": "An error code (see below)", "message": "A description of the error, parsed from the platform error", "platform_error": "The full error message returned by the integration platform" } } ``` > [!NOTE] > > **Accuracy of error codes** > > Most errors are classified deterministically: first by integration-specific handling, then by HTTP status (`429` becomes `rate-limit-exceeded`, `401`/`403` become `access-denied`). Only a **write** error that none of those recognise falls through to LLM-based mapping, which picks the closest error code and writes the message. Read failures never take that path — they surface as `unknown-error`. > > Where the LLM is involved the code may not be exact. `platform_error` is always the unmodified response from the platform, so prefer it when debugging. ## Error codes Write APIs return `400` with one of the following codes. | Error code | Description | | - | - | | `missing-params` | A field the platform requires was not provided. | | `invalid-params` | A field was provided but the platform rejected its value. | | `record-already-exists` | A record already exists on the platform with the given field. | | `record-not-found` | The referenced record does not exist on the platform. | | `operation-denied` | The platform refused the operation. | | `platform-denied` | The platform denied the request outright. | | `access-denied` | The connection lacks the access required for this operation. Check the data model's `scope_access` in your [sync config](/documentation/concepts/sync-config). | | `token-expired` | The connection's access token has expired. The customer needs to re-authenticate. | | `invalid-refresh-token` | The stored refresh token is no longer valid. The customer needs to re-authenticate. | | `already-disconnected` | The connection is already disconnected. | | `rate-limit-exceeded` | The underlying platform's rate limit was hit. Retry with backoff. | | `unknown-error` | The platform error could not be mapped to a known code. | > [!WARNING] > > **Internal errors** > > An internal failure returns `500` with the `internal-error` code. If you receive it, contact [support@commenda.io](mailto:support@commenda.io) — we monitor internal errors and will investigate. ## Connection state and writes Writes require a **healthy** connection. If the connection is expired or disconnected, the write is rejected before it reaches the platform, and the customer must re-authenticate. Subscribe to the [`CONNECTION_CHANGED` webhook](/documentation/concepts/webhooks#connection-changed) to catch this as it happens rather than on the next failed write. # Partner Credentials Source: https://integrations.docs.commenda.io/documentation/concepts/partner-credentials Learn how you can leverage your own platform partnerships with RootFi ## Introduction If you're already partnered with or have developer accounts with the platforms we're integrating, RootFi empowers you to bring your own credentials and settings. ## Partner Credentials and Options Your partner credentials and options could include OAuth master-level credentials, which are instrumental for issuing access tokens and initializing OAuth flows. This customization allows you to showcase your brand's logo and name within the OAuth flow, instead of RootFi's. ## Default Credentials In most cases, RootFi offers a set of default credentials and settings, eliminating the need to establish partnerships with each integrated tool. > [!WARNING] > > **Default Credentials not available for Xero** > > Due to the nature of Xero's OAuth restrictions, we are unable to provide default credentials for Xero. You will need to provide your own credentials to integrate with Xero. Learn how to [setup your own Xero's OAuth credentials](/accounting-integrations/xero). ## Configuring Credentials When updating credentials, exercise caution to avoid disrupting your integration. Common pitfalls involve discrepancies in the redirect URL or insufficient access scopes. We recommend thoroughly testing the new credentials within your development environment and reaching out to RootFi if you encounter any ambiguities or issues. ## Making Changes Modifying credentials is a straightforward process and can be accomplished through the integrations page for any supported integrations. Changing credentials does not affect existing integrations as we continue to utilize the old credentials for them. To transition existing integrations to the new credentials, simply ask your customer to link their account again. # Reading Data Source: https://integrations.docs.commenda.io/documentation/concepts/reading-data Use our read APIs for quick easy access to your customers data Data is read over REST. Every unified data model is available under a company: ``` GET /v4/core/companies/{companyId}/{data_model} GET /v4/core/companies/{companyId}/{data_model}/{id} ``` ## Query parameters | Parameter | Description | | - | - | | `limit` | Number of records to return. Defaults to **20**, maximum **100**. | | `next` / `prev` | Cursor pagination. Both are returned in the response — pass one back to page forward or backward. | | `expand` | Comma-separated list of related objects to include inline. The supported values differ per data model; see the model's API reference page. | | `include_deleted_records` | Boolean. Include records deleted since the last sync. Deleted records are excluded by default. | | `return_count` | Boolean. `total_count` is returned by default. Pass `return_count=false` to skip the count query and get a faster response when you don't need the total; `total_count` then comes back as `0`. | | `sort[field]` | `asc` or `desc`. Only certain fields are sortable per model. | | `period` | Integer. Rolls up consecutive monthly rows on `income_statements`, `balance_sheets`, and `cash_flow_statements` only. See [Financial statement rollup](#financial-statement-rollup). | ## Filtering Filters use the form `field[operator]=value`. These operators are supported: | Operator | Meaning | | - | - | | `eq` | Exact match | | `in` | Matches any value in a comma-separated list | | `gte` | Greater than or equal to | | `lte` | Less than or equal to | | `is_null` | `true`: only records where the field is null. `false`: only records where it is not null | | `not_null` | `true`: only records where the field is not null. `false`: only records where it is null | ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies/694/invoices?status[eq]=PAID&limit=50" \ -H "api_key: YOUR_API_KEY" ``` Filtering by an updated-at range is the usual way to pull everything that changed since your last sync: ``` ?rootfi_updated_at[gte]=2024-01-01T00:00:00.000Z ``` > [!WARNING] > > **Not every field is filterable.** Each data model exposes its own set of filterable fields — a filter on an unsupported field is ignored rather than applied. Check the model's API reference page for the fields it accepts. Operators cannot be combined on the same field. These all return `400`: * `eq` together with `in` * `eq` together with `gte` or `lte` * `in` together with `gte` or `lte` * `is_null` or `not_null` together with any other operator, including each other `is_null` and `not_null` accept only `true` or `false`, and only on fields that can be null; on a field that is never null they return `400`. To filter on a missing value, use `contact_type[is_null]=true` rather than `eq` with `null`. Filtering an enum field on a value outside the enum returns `400` with the list of valid values. Currency codes are stored uppercase but accept lowercase input. ## Response shape List responses return the records at `data`, with pagination as a sibling: ```json theme={null} { "data": [{ "rootfi_id": 1, "...": "..." }], "pagination": { "total_count": 143, "next": "cursor", "prev": null }, "request_id": "req_..." } ``` Single-record responses return the object at `data`, with no `pagination`. `total_count` is populated unless you pass `return_count=false`. ## Raw platform data Records can include `raw_data` — the untouched response from the source platform. > [!NOTE] > > `raw_data` is only included for paying customers — it is stripped from read responses otherwise. Contact [support@commenda.io](mailto:support@commenda.io) if you need it enabled. When it is returned it carries the full upstream payload for every record, so responses are heavier than the documented field list suggests. Lower `limit` if you hit slow responses or size limits. See [Raw Data](/documentation/concepts/supplemental-data/raw-data) for how to use it, including on writes. ## Financial statement rollup `income_statements`, `balance_sheets`, and `cash_flow_statements` are stored as monthly rows. Pass `period` to roll consecutive months into larger buckets — `period=3` for quarters, `period=12` for years. `period` requires both `period_start[gte]` and `period_end[lte]` — omitting either returns `400`. It returns the complete rolled-up list rather than a page, so passing `next` or `prev` alongside it returns `400`, as does combining it with `expand`. ```bash theme={null} curl -X GET "https://api.integrations.commenda.io/v4/core/companies/694/income_statements?period=3&period_start[gte]=2024-01-01&period_end[lte]=2024-12-31" \ -H "api_key: YOUR_API_KEY" ``` The rollup loads every statement row in the requested window before bucketing, and rejects the request with `400` above 10,000 rows. If you hit it, narrow `period_start[gte]` / `period_end[lte]`. # Embedded SDK Source: https://integrations.docs.commenda.io/documentation/concepts/rootfi-connect/embedded-sdk RootFi supports white labelling the onboarding process through the Connect SDK. Your end users can create connections to their platforms without using the RootFi dashboard to generate [Invite Links](/documentation/concepts/rootfi-connect/invite-link). We currently offer a Javascript SDK but you can request other frameworks by contacting us. ### Developer Reference 1. Create an invite link by calling the Create Invite Link API (`POST /v4/core/invite-links`). 1. If `company_name` is not passed, company wont be created and so, your user will have to enter it in the SDK. 2. To enable only certain integrations, you can pass a list of `integrations`. If only one integration is passed, user will be redirected to the platform login url directly. 2. The response will contain the `invite_link`, which will need to be sent to the SDK during initialisation, and the `company_id`, which you should store to uniquely identify this customer. ### Setup SDK 1. Import the source script in the head tag. Default: `` KSA region: `` 2. Load the RootFi SDK on page load by calling `RootfiLink.initialize()`. ```javascript JavaScript theme={null} RootfiLink.initialize({ linkToken: "", // invite_link returned from the Create Invite Link API onSuccess: () => { // Will be called, once connection is successful }, onReady: () => { // Will be called once the src script is loaded }, onExit: () => { // Will be called when user clicks close button on SDK. }, }); ``` 1. Call `RootfiLink.openLink();` to open the SDK. Make sure you call this function onReady is called back on initialisation. 2. Call `RootfiLink.closeLink();` to close the SDK. You can use this method to close the SDK in **onSuccess** and **onExit** Callback; > [!WARNING] > > The SDK will not close until you call `RootfiLink.closeLink();` Below is a HTML snippet of integrating the SDK and a ReactJS implementation using our react SDK component. ```html HTML theme={null}

``` ```javascript React theme={null} import { useEffect, useState } from "react"; import { useRootfiLink } from "rootfi-react-sdk"; const ConnectSDK = () => { const [inviteLinkId, setInviteLinkId] = useState(""); const { isReady, closeLink, openLink } = useRootfiLink({ environment: "global", // "global" or "saudi" inviteLinkId: inviteLinkId, onSuccess: (data) => { // connection succeeded // Make an api call to save success status to your db setTimeout(() => closeLink(), 2000); }, onExit: () => { closeLink(); }, }); useEffect(() => { // Call Create Invite Link API to get a new invite link and set it to the state // setInviteLinkId("INVITE_LINK_ID"); }, []); if (!isReady) return <>{"Initialising SDK"}; return (
); }; export default ConnectSDK; ``` # Introduction Source: https://integrations.docs.commenda.io/documentation/concepts/rootfi-connect/introduction Explore how your customers can authorize access to their data Authorization is a crucial part of RootFi - every customer must authorize access to their data before you can pull or push data to their platform. A frictionless and secure authorization flow is essential for accessing your customers' data, which is what RootFi offers. ## Intro to Connect by RootFi Connect by RootFi streamlines the process of connecting your application to various accounting platforms, providing two efficient methods for integration: 1. [Invite Link](/documentation/concepts/rootfi-connect/invite-link) 2. [Connect SDK](/documentation/concepts/rootfi-connect/embedded-sdk) These solutions are designed to cater to different use cases and requirements, ensuring seamless integration and data access. ### Invite Link: No-Code User Integrations The Invite Link is a no-code solution that enables you to connect your end users to accounting platforms without writing any frontend code. This approach delivers a smooth, in-browser experience and simplifies the integration process for both you and your customers. #### Key features of the Invite Link: * **Easy to implement:** Simply generate a unique URL that your users can visit to connect their accounting platform to your application. * **Customizable:** Personalize the connection process by modifying the appearance and behavior of the link, such as only displaying platforms that are relevant to your customer and prefilling the customer's company name. * **Secure:** RootFi's Invite Link ensures secure connections with end-to-end encryption and adherence to industry standards. > [!NOTE] > > **Get Started with the RootFi Invite Link** > > Learn how you can start onboarding customers with a shareable link using the [Invite Link](/documentation/concepts/rootfi-connect/invite-link) ### Connect SDK: Frontend Integration with Flexibility The Connect SDK is a software development kit that provides a more customizable, flexible, white-labelled, fully-embedded solution for integrating your customer's platforms into your application, optimized for conversion and building trust. With RootFi's Connect SDK, you have full control over the user interface and can tailor the integration process to fit your specific needs. #### Key features of the Connect SDK: * **Highly customizable:** Skip configuration screens by providing the information upfront, add your logo and choose how to handle success and error flows to match your application's requirements and design. * **Robust documentation:** Access comprehensive documentation to guide you through the integration process. * **Seamless integration:** The Connect SDK is designed to work smoothly with your existing tech stack, making it easy to incorporate into your application. > [!NOTE] > > **Get Started using Connect SDK** > > Learn how you can embed onboarding in your application with [Connect by RootFi SDK](/documentation/concepts/rootfi-connect/embedded-sdk) # Invite Link Source: https://integrations.docs.commenda.io/documentation/concepts/rootfi-connect/invite-link Integrate your end users without any frontend code ## Overview of the Invite Link Our Invite Link allows you to invite customers to authorize data access by delivering an in-browser experience without any frontend code. The Invite Link is a unique and secure URL that needs to be sent to your end users. #### Benefits of using the Invite Link: * Fast proof of concept of RootFi without making any frontend changes, such as embedding the Connect SDK into your application * Your users can authorize integrations without logging into your application i.e sending URLs via email ### Generate Invite Link An Invite Link can be generated in two ways: 1. From your RootFi dashboard (No-code and beginner-friendly) 2. Programmatically via API (Intermediate) #### Via the RootFi Dashboard You can initialize an Invite Link from the RootFi Dashboard in three easy steps. 1. Navigate to Companies in the left navigation 2. On the top right corner of the page, click the Invite a Company button 3. Click Generate URL, and copy the URL That's it! You will be presented with a unique URL that you can send to your customer. #### Via API Refer to our Invite Link API (`POST /v4/core/invite-links`) for more details on how to generate Invite Links programmatically. Using the API, you can customize the behavior of the link, such as only displaying platforms that are relevant to your customer, prefilling the customer’s company name, setting up a custom sync configuration for this connection. After generating an Invite Link, you can send your customer an invite URL: Default: `https://sdk.integrations.commenda.io/?invite_link_id=INVITE_LINK_ID` KSA Region: `https://sdk.integrations.sa.commenda.io/?invite_link_id=INVITE_LINK_ID` Alternatively you can use the [Connect SDK](/documentation/concepts/rootfi-connect/embedded-sdk) to embed the onboarding experience in your application. # Passthrough API Source: https://integrations.docs.commenda.io/documentation/concepts/supplemental-data/passthrough-api Call any underlying API using RootFi Use the Passthrough API (`POST /v4/core/passthrough`) to call any endpoint on the underlying platform directly. This is useful when you need to read or write something our unified models do not cover. You just need to pass in the correct API config data: * Method: `GET`, `POST`, `PUT`, `PATCH`, `DELETE` * URL Path: The URL path of the API you want to call * Headers: Any headers that are required for the API call * Parameters: Any parameters that are required for the API call * Data: Any data that is required in the body of the API call We will handle the authentication to call the API for that platform and return the response data. If you need help finding the right API configuration for a platform, contact [support@commenda.io](mailto:support@commenda.io). # Raw Data Source: https://integrations.docs.commenda.io/documentation/concepts/supplemental-data/raw-data Learn how to interact with the platforms data in the original format. Sometimes you need a field from the underlying platform that we do not unify. Every data model carries a `raw_data` field for exactly that. ## Reading data `raw_data` contains the entire response from the underlying platform for that record, so you can reach any field we do not unify. > [!NOTE] > > **`raw_data` is only included for paying customers** > > It is stripped from read responses otherwise. Contact [support@commenda.io](mailto:support@commenda.io) if you need it enabled for your organization. When it is returned, `raw_data` is included on every record automatically — there is no parameter to opt in or out. Because it carries the full upstream payload, responses are heavier than the documented field list suggests, so lower `limit` if you hit slow responses or size limits. ## Writing data You can pass a JSON object in the `raw_data` field when writing data. Every field inside `raw_data` is passed straight through to the underlying platform. Check the platform's own documentation for the field name and type you want to push. If you run into trouble, contact us and we are happy to help. > [!TIP] > > **Adding to our Unified API** > > If there is a field you keep reaching for through `raw_data` and think it should be unified, contact us and we are happy to discuss. # Sync Frequency & Scopes Source: https://integrations.docs.commenda.io/documentation/concepts/sync-config Configure which data syncs, how often, and what level of access is requested from the integration. Sync config controls, per data model: whether it syncs, how often, what access we request from the platform, and how far back to sync. It is set at the organization level and can be overridden per company. ## The shape of a sync config Each entry covers one data model: | Field | Description | | - | - | | `data_model` | The data model the entry applies to, e.g. `INVOICE`. | | `category` | The integration category the data model belongs to, e.g. `ACCOUNTING`. | | `enabled` | Whether the data model syncs at all. | | `frequency` | How often Auto Sync runs for this model. See below. | | `interval` | How many units of `frequency` to wait between syncs. Minimum `1`. | | `scope_access` | Which operations to request access for. See below. | | `sync_from` | Optional ISO date. Restricts historical sync to that point forward. | Entries that fail validation — an `interval` below `1`, an unknown `frequency` — are skipped rather than rejecting the whole config, so a malformed entry silently drops that data model from the sync. ### Frequency `frequency` is one of **`HOURLY`**, **`DAILY`**, **`WEEKLY`**, **`MONTHLY`**, **`YEARLY`**, or **`NEVER`**. `interval` multiplies it, so the pair sets the real cadence: * `frequency: DAILY`, `interval: 1` — once a day * `frequency: HOURLY`, `interval: 6` — every six hours * `frequency: WEEKLY`, `interval: 2` — every two weeks `NEVER` disables Auto Sync for that model while still allowing manual syncs. > [!NOTE] > > Pick the slowest frequency that meets your needs. The underlying platform's rate limits are shared across every data model and your writes — see [Syncing Data](/documentation/concepts/syncing-data). ### Access `scope_access` is four independent booleans, not a single level: ```json theme={null} "scope_access": { "READ": true, "CREATE": true, "UPDATE": false, "DELETE": false } ``` Grant only what you use. The access you select determines the OAuth scopes we request from the platform, so over-requesting means asking your customers to consent to more than necessary. > [!NOTE] > > **Raising access after a customer has connected** > > We only request the access level your config specifies at connection time. If you need more later, most integrations require the customer to re-authenticate to grant the additional scopes. ## OAuth scopes Scopes are the permissions your end customer grants for us to access their data. When a customer connects their platform, they see the data models and access levels you configured. We then request OAuth scopes matching those permissions. Most platforms also display the scopes being granted, so the customer sees the scope of data sharing before consenting. ## Per-company overrides Sync settings can be overridden for an individual company; the override replaces the organization-level config rather than merging with it. > [!NOTE] > > An override must list **every** data model you want synced — models absent from it do not fall back to the organization config. > > Two adjustments happen on top of your entries at connection time: the config is filtered to data models the integration actually supports, and data models added to the platform after your config was written are appended with defaults so they still sync. Set an override when creating an invite link, or later: * `PATCH /v4/core/companies/{companyId}/sync-config` * `POST /v4/core/companies/{companyId}/sync-config/reset` — drop the override and fall back to the organization config * `POST /v4/core/companies/{companyId}/sync-config/reset/{dataModel}` — reset a single data model * `GET /v4/core/organizations/sync-config` and `POST /v4/core/organizations/sync-config` — read and set the organization default Per-integration access requirements are covered in each [integration's setup guide](/accounting-integrations/accounting-integrations-overview). # Syncing Data Source: https://integrations.docs.commenda.io/documentation/concepts/syncing-data Learn how we keep your customers data up-to date There are two ways data gets synced: 1. **Auto Sync** — runs on a frequency you configure, per data model. Always incremental. 2. **Manual Sync** — triggered by you, from the dashboard or the API. Incremental, full, or from a specific date. | | **Auto** | **Manual** | | - | :-: | :-: | | **Incremental** | ✅ | ✅ | | **Full** | | ✅ | | **Sync from X Date** | | ✅ | Only a manual sync takes a start date per request. Auto Sync always runs incrementally from the last successful sync — but the `sync_from` you set in [Sync Config](/documentation/concepts/sync-config) acts as a floor for every sync, Auto included, so historical data before that date is never pulled. The three modes: 1. **Incremental Sync (default)** — only syncs data changed since the last sync. 2. **Full Sync** — syncs everything from the underlying platform. Trigger this when you need records deleted on the platform to be reflected on our side; deletions are only detected during a full sync. 3. **Sync from a specific date** — syncs data from a given date forward, per data model. Useful when a customer has a large history and you only need recent data. > [!WARNING] > > **Sync only the data you need** > > Sync only the data models you actually use. This avoids exhausting the underlying platform's rate limits, shortens sync time, and limits exposure of sensitive data. ## Auto Sync Auto Sync checks for updates and incrementally syncs data for all active connections at the frequency you set. [Sync Config](/documentation/concepts/sync-config) controls the frequency per data model, so you can sync what you care about often and everything else rarely. > [!NOTE] > > **Why frequency per data model matters** > > The underlying platform's rate limits are the real constraint. If a customer has a lot of data and every data model is set to sync frequently, syncs get paused and resumed against those limits — so the models you actually care about may not be as fresh as you expect. Frequent syncing also competes for the same API quota as your writes. ## Manual Sync ### Via the dashboard Trigger a manual incremental sync for a customer from the company page. Every enabled data model is synced. ### Via API `POST /v4/core/companies/{companyId}/syncs` By default this is an incremental sync of all configured data models. The body is optional: ```json theme={null} { "fullSync": false, "dataModelsToSync": [ { "dataModel": "INVOICE", "syncFrom": "2024-01-01T00:00:00Z" }, { "dataModel": "CONTACT" } ], "notifyAllSyncedRecords": false } ``` | Field | Description | | - | - | | `fullSync` | Sync everything from the platform rather than only what changed. Required for deletions to be detected. | | `dataModelsToSync` | Restrict the sync to specific data models. Omit to sync every configured model. | | `dataModelsToSync[].dataModel` | A `DataModel` value — **singular**, e.g. `INVOICE`, `BILL`, `CONTACT`. | | `dataModelsToSync[].syncFrom` | ISO 8601 timestamp. Only sync this model's data from that point forward. | | `notifyAllSyncedRecords` | Fire update webhooks for records that were fetched but unchanged. | The response returns the sync id and the data models that are syncing. Track progress with `GET /v4/core/companies/{companyId}/syncs`, or subscribe to the [`SYNC_STARTED` and `SYNC_COMPLETED` webhooks](/documentation/concepts/webhooks). > [!WARNING] > > **Syncing from a specific date** > > Base data models like accounts and contacts should always be synced in full. Other models — invoices, bills — reference them, so restricting them to a date window causes dangling references. # Webhooks Source: https://integrations.docs.commenda.io/documentation/concepts/webhooks Listen to real-time events from the platform. Webhooks keep your systems in sync without polling. When data is synced from a connected platform, a connection changes state, or an end user requests a disconnect, we POST a JSON event to a URL you control. ## Event types | Event | Fires when | | - | - | | `DATA_MODEL_CHANGES` | Synced records are created, updated, or deleted | | `SYNC_STARTED` | A sync begins | | `SYNC_COMPLETED` | A sync finishes | | `CONNECTION_CHANGED` | A company's connection status changes | | `DISCONNECT_REQUESTED` | An end user requests a disconnect from the SDK | Each webhook you configure subscribes to exactly one event type. ## Payload envelope Every event body has the same two-key shape. The event type is in `event`, and everything else is under `data`: ```json theme={null} { "event": "SYNC_STARTED", "data": { } } ``` ## Events ### Data Model Changes Fires as records are written during a sync. Use it to mirror our data into your own store. ```json theme={null} { "event": "DATA_MODEL_CHANGES", "data": { "company_id": 1234, "integration_type": "XERO", "data_model": "INVOICE", "type": "CREATE", "job_id": "amiKRBIQ1khvk6B", "sync_id": "pt21IJtaATVZJ5v", "no_of_records": 50, "records": [ { "platform_id": "3124930487", "...": "..." }, { "platform_id": "3147384833", "...": "..." } ] } } ``` `type` is one of: * **CREATE** — data is synced for the first time, or a new record appears on the connected platform. * **UPDATE** — a record actually changed. Not sent on every sync: if we sync daily and the platform reports no changes, you get nothing. * **DELETE** — a record was removed on the connected platform. Only detected during a [full sync](/documentation/concepts/syncing-data). > [!WARNING] > > **Records are batched and paged.** Each delivery carries at most 50 records in `records`, so a single sync of a large data model produces many deliveries. Records are deduplicated by `platform_id` within a batch. Treat `records` as a page, not the complete set for that `sync_id`. > [!NOTE] > > **The same record can arrive more than once in a sync.** A record is re-sent as **UPDATE** whenever any of its fields changed since the last fetch — including fields you may not care about. On Stripe invoices the hosted payment link is regenerated on every fetch, so most invoices arrive as a **CREATE** and then again as an **UPDATE** with no other field changed. > > Deduplicate on `platform_id` and compare the fields you actually use, rather than treating every **UPDATE** as a meaningful change. For a full sync, this event delivers the entire dataset — records that were already up to date arrive as **UPDATE**. ### Sync Started ```json theme={null} { "event": "SYNC_STARTED", "data": { "sync_id": "pt21IJtaATVZJ5v", "company_id": 1234, "integration_type": "XERO", "data_models": ["INVOICE", "CONTACT"], "full_sync": false } } ``` ### Sync Completed Fires once an asynchronous sync finishes. Use it to check which data models succeeded and which failed. ```json theme={null} { "event": "SYNC_COMPLETED", "data": { "id": "pt21IJtaATVZJ5v", "sync_id": "pt21IJtaATVZJ5v", "type": "PULL", "status": "SUCCESS", "start_time": "2024-05-16T11:27:22.000Z", "end_time": "2024-05-16T11:27:38.743Z", "total_jobs_count": 15, "success_jobs_count": 15, "failed_jobs_count": 0, "running_jobs_count": 0, "created_jobs_count": 0, "data_models": ["INVOICE", "CONTACT"], "company_id": 1234, "integration_type": "XERO" } } ``` `status` is derived from the job counts: `SUCCESS` when every job succeeded, otherwise `FAILED`, `RUNNING`, or `CREATED`. A partial failure surfaces as `FAILED` with a non-zero `failed_jobs_count` — inspect the counts rather than treating the event as all-or-nothing. `id` and `sync_id` carry the same value; prefer `sync_id`. ### Connection Changed Fires when a connection is established via an invite link, or when its status changes — including expiry and disconnection. Use it to prompt customers to reconnect. ```json theme={null} { "event": "CONNECTION_CHANGED", "data": { "connection_id": "1234_XERO", "company_id": 1234, "integration_type": "XERO", "status": "HEALTHY" } } ``` `status` is one of `HEALTHY`, `EXPIRED`, or `DISCONNECTED`. `connection_id` is the composite `{company_id}_{integration_type}`. ### Disconnect Requested ```json theme={null} { "event": "DISCONNECT_REQUESTED", "data": { "disconnect_request_id": 42, "connection_id": "1234_XERO", "company_id": 1234, "integration_type": "XERO" } } ``` > [!WARNING] > > **This event does not disconnect anything.** An end user in the SDK is *requesting* that you disconnect their integration. The connection stays active and keeps syncing until an authenticated dashboard user resolves the request. Subscribe to this event so those requests reach a human instead of sitting unnoticed. ## Topics Topics narrow a `DATA_MODEL_CHANGES` webhook to the changes you care about. A topic is a data model and an operation, both lowercase: ``` invoice.create invoice.update contact.delete ``` Retrieve the full list of valid topics from `GET /v4/core/webhook-config/platform-topics`. Invalid topics are rejected when you create or update the config. > [!NOTE] > > A `DATA_MODEL_CHANGES` webhook with an empty topic list matches **every** data model and operation. The dashboard requires you to pick at least one topic; the API does not. If you create configs through the API, set topics explicitly unless you truly want everything. The other event types ignore topics. ## Configuring a webhook > [tab] Dashboard > > 1. Go to **Webhooks** and click **Create Webhook**. > 2. Name the webhook and choose the event type. > 3. For **Data Model Changes**, select the topics to subscribe to. > 4. Enter your endpoint URL. Optionally add custom headers, and a signing key so you can verify that deliveries came from us. > > Existing configs are listed on the **Webhooks** page, where you can enable, disable, or edit them, and open a delivery to see its attempts and response codes. > [tab] API > > Create a config with `POST /v4/core/webhook-config`: > > ```json theme={null} > { > "name": "Invoice changes", > "webhook_type": "DATA_MODEL_CHANGES", > "url": "https://api.example.com/hooks/rootfi", > "topics": ["invoice.create", "invoice.update"], > "headers": [{ "name": "X-Tenant", "value": "acme" }], > "signing_key": "" > } > ``` > > The full set of config endpoints is in the API reference under **WebhookConfig**. ## Delivery All webhooks are sent as `POST` requests with a JSON body. The body is exactly the event payload — there is no additional wrapper. ### Headers | Header | Description | | - | - | | `Content-Type` | Always `application/json` | | `X-RootFi-Webhook-Delivery-Id` | Unique id for this delivery. Stable across retries — use it to deduplicate | | `X-RootFi-Timestamp` | Unix timestamp (seconds) when the delivery was attempted | | `X-RootFi-Signature` | HMAC signature. Sent only when the config has a signing key | Any custom headers on the config are also sent. If the originating event carried `x-request-id`, `x-correlation-id`, or `x-trace-id`, those are forwarded too. Our own `X-RootFi-*` headers take precedence over custom headers with the same name. ### Retries A delivery succeeds on any `2xx`. Anything else — including a timeout — is retried up to **5 attempts** total, with exponential backoff of `min(60 × 2^attempt, 900)` seconds: roughly 1 min, 2 min, 4 min, 8 min, then capped at 15 min. Requests time out after 30 seconds. After the final failed attempt the delivery is marked failed and not retried again. Deliveries are also dropped if the config is disabled or deleted before they are sent. > [!TIP] > > Return a `2xx` as soon as you have durably accepted the payload, and do your processing asynchronously. Slow handlers burn into the 30-second timeout and trigger retries you don't want. Delivery history, attempt counts, and response codes are available via `GET /v4/core/webhook-logs` and in the dashboard. ### Verifying signatures When a config has a signing key, we sign each delivery and send the result in `X-RootFi-Signature`: ``` X-RootFi-Signature: t=1716035258,v1=5257a869e7d0a1b... ``` `t` is the unix timestamp and `v1` is a hex HMAC-SHA256. The signed message is the timestamp, a literal `.`, and the **raw** request body: ``` HMAC-SHA256(signing_key, "{t}.{raw_body}") ``` To verify: parse `t` and `v1`, recompute over the raw body, and compare in constant time. Sign the bytes you received — re-serializing parsed JSON changes key order and whitespace, and the signature will not match. ```javascript theme={null} import crypto from "crypto"; function verify(rawBody, header, signingKey, toleranceSeconds = 300) { const [, t, v1] = header.match(/^t=(\d+),v1=([a-f0-9]+)$/i) ?? []; if (!t) return false; if (Math.abs(Date.now() / 1000 - Number(t)) > toleranceSeconds) return false; const expected = crypto.createHmac("sha256", signingKey).update(`${t}.${rawBody}`).digest("hex"); if (v1.length !== expected.length) return false; return crypto.timingSafeEqual(Buffer.from(expected, "hex"), Buffer.from(v1, "hex")); } ``` Rejecting timestamps outside a tolerance window (300 seconds is a reasonable default) limits replay attacks. ## Handling events reliably * **Deduplicate on `X-RootFi-Webhook-Delivery-Id`.** Retries reuse the id, and at-least-once delivery means you may see the same event twice. * **Don't assume ordering.** Deliveries are queued independently; a `SYNC_COMPLETED` can arrive before the last `DATA_MODEL_CHANGES` batch of that sync. * **Treat `records` as one page of many.** Reconcile against `sync_id` rather than expecting a single complete payload. * **Upsert rather than insert.** Combined with partial data, the same `platform_id` will legitimately arrive more than once. # Writing Data Source: https://integrations.docs.commenda.io/documentation/concepts/writing-data Push data to your customers' platform through a single API. Writes go to the same company-scoped route as reads: ``` POST /v4/core/companies/{companyId}/{data_model} # create PUT /v4/core/companies/{companyId}/{data_model} # update ``` The payload goes under `data`: ```bash theme={null} curl -X POST "https://api.integrations.commenda.io/v4/core/companies/694/invoices" \ -H "api_key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "data": { "contact_id": "123", "total_amount": 100 } }' ``` Which data models support writes depends on the integration. Attempting an unsupported write returns `400` naming the integration and data model. You can check field-level support in our [coverage tool](https://coverage.integrationlabs.co/). > [!NOTE] > > **Writes require a healthy connection** > > If the connection is expired or disconnected the write is rejected before it reaches the platform. See [Error Handling](/documentation/concepts/error-handling). ## Synchronous writes **Writes are synchronous by default.** Latency depends on the integration — we add only the overhead of mapping and logging. > [!NOTE] > > **Some calls take much longer than others** > > This comes from the integration itself: a single unified write sometimes requires several calls to the platform. ## Asynchronous writes Pass `run_async=true` as a query parameter: ``` POST /v4/core/companies/{companyId}/invoices?run_async=true ``` The response returns a `sync_id`. Track it with `GET /v4/core/companies/{companyId}/syncs`, or subscribe to the [`SYNC_COMPLETED` webhook](/documentation/concepts/webhooks#sync-completed). We recommend async for large datasets — rate limiting and retries are handled for you. ### Batch writes Send `data` as an array of objects. All records in the batch share one `sync_id`. ```json theme={null} { "data": [ { "contact_id": "123", "total_amount": 100 }, { "contact_id": "456", "total_amount": 250 } ] } ``` > [!WARNING] > > **Batches require `run_async=true`** > > Sending more than one record with `run_async=false` (or omitted) returns `400`. Either pass `run_async=true` or send one record per request. **One data model per request.** To write 10 invoices and 10 bills, call the invoices endpoint and the bills endpoint separately. ## Uploading documents Documents use a dedicated endpoint, `POST /v4/core/companies/{companyId}/documents`, and accept either a multipart file upload or a base64-encoded file in the JSON body. Each document attaches to a parent record via `document_type` and `document_type_id`. # Glossary Source: https://integrations.docs.commenda.io/documentation/general/glossary-key-terms Understand core concepts and key terms used in Integrations by Commenda (formerly RootFi) solutions. As you read through this documentation, you will encounter several core concepts and terms that are central to our products. Understanding these concepts and terms is essential for effectively utilising our products and making the most of their features and capabilities. | Term | Description | | - | - | | Platform | Refers to the accounting software, e-commerce platform, or payment processor used by your Customer. (Eg. - Zoho Books, Amazon, etc.) | | Customers | A customer represents a user who has granted you access to view a subset of their accounting data—referred to as their consented data. | | Connection | When a Customer successfully authorises access to a Platform. If a Customer uses Zoho books and Amazon and authorizes connections to both, that would be considered as two separate connections. Connections are established when a Customer completes the authorisation process using [Connect by Commenda](/documentation/concepts/rootfi-connect/introduction). Each Connection will have a unique access token, which is used to make API calls. | # Introduction Source: https://integrations.docs.commenda.io/documentation/general/introduction Learn how Integrations by Commenda helps you securely access your customers’ financial data and connect it directly to Commenda’s tax and compliance engine. > [!NOTE] > > We’ve fine-tuned ChatGPT specifically for our Documentation. Simply type your query into the search bar to receive precise answers that align with your needs. ## What is Integrations by Commenda (formerly RootFi)? Integrations by Commenda (formerly RootFi) is a data integration platform that makes it easy for companies to connect their apps to their customers' accounting, payments and e-commerce platforms, with more categories soon. We provide a well-documented Unified API that product teams use to read and write data to our growing portfolio of platforms. Companies use Integrations by Commenda (formerly RootFi) to underwrite credit risk, automate accounting, surface business insights and seamlessly integrate their products with Commenda’s tax and compliance engine. Our API saves product teams hundreds of hours and thousands of dollars that would have otherwise been spent building these API integrations in-house. You can reach out to us by emailing us at [operations@commenda.io](mailto:operations@commenda.io). *** ## Unified APIs ### What are Unified APIs? A Unified API (Or universal API) aggregates APIs in the same software category like accounting, payments, CRM, and e-commerce. It makes integration with various platforms easier through a standard endpoint, handling authentication, and providing normalized data models. For example, reading invoice data from an enterprise ERP like Oracle NetSuite will look the same as reading invoice data from an SME focused, on-premsie platform like Tally. Using Integrations by Commenda (formerly RootFi), your solution can leverage the same, normalized set of fields, regardless of the underlying platforms. # Accounts Payable (AP) Source: https://integrations.docs.commenda.io/guides/accounts-payable This guide helps Accounts Payable companies automate the collection and reconciliation of bills, bill payments, credit notes, and purchase orders with their customers' respective accounting systems. *** ## Introduction Accounting integrations are crucial for bridging the gap between your AP automation solution and your customers' accounting software. This guide outlines how to leverage accounting integrations through RootFi' Unified Accounting API, facilitating the development of an end-to-end automated AP product. *** ## What is the Accounts Payable (AP) Workflow? 1. **Bill Collection**: Capture and log bills received from suppliers. 2. **Bill Verification**: Validate bill details against purchase orders. 3. **Execute Approval**: Route bills for approval based on predefined workflows. 4. **Payment Processing**: Execute payment to suppliers upon approval. 5. **Reconciliation**: Match bills and bill payments with transactions in accounting systems. Integration with accounting systems is essential to automate these steps, particularly for reconciliation, ensuring transactions are accurately recorded in your customers accounting software. *** ## The Role of Accounting Integrations and RootFi' Unified Accounting API While essential, developing and maintaining multiple accounting integrations in-house is resource-intensive. RootFi' Unified API simplifies this process by providing a single API to connect with over 20 accounting platforms. The benefits of a Unified API include: * **Global Connectivity**: Simplifies integration with multiple accounting platforms, ensuring maximum coverage for current and future customers. * **Accelerated Go-to-Market**: Integrating with one Unified API significantly reduces the time required to build, test, and launch an integrated product. * **Cost Savings**: Lowers the overall cost of developing and maintaining integrations, allowing resources to focus on core product development. * **Maintenance Ease**: Offloads integration maintenance responsibilities, enabling your team to focus on core product enhancement. Adopting RootFi' Unified API speeds up the development process and adds significant value to your Accounts Payable (AP) solution, making it more reliable and easier to integrate with customers' preferred accounting systems. *** ## How to Build an Automated Accounts Payable (AP) Product with a Unified Accounting API You can handle all of the common workflows required to offer your customers an Accounts Payable (AP)/ Bill Payment product. Here's a summary of the steps involved: 1. (One-Time Activity) Connect a customer's accounting systems with RootFi' **Authentication Flow**. 2. Use the **Bills API** to create a Bill and link Contacts, Purchase Orders, Items, and Accounts to the respective Bill. 3. Upload **Documents** to their respective Expense/Bill. 4. Create and Link Bill Payments, Purchase Orders, Good Reciept Notes, Bill Credit Notes, Contacts and Open Bills. *** ## 1. Connect with your customers' accounting platform (One-Time Activity) RootFi provides two convenient options to connect with your customers' accounting platform: 1. Use RootFi' **Connect Link**, a convenient and secure URL, **or** 2. Embed RootFi' **Connect SDK** into your application The Invite Link requires no code, making it suitable to start without a developer. You can customize and white-label this onboarding process with RootFi' Connect SDK, allowing authentication to occur natively in your product. Either way, your customers will be guided through a simple authorization flow to connect their accounting platforms to your product. 1. Use our Dashboard or APIs to connect a customer's accounting platform. Use [**POST/invite-links**](/documentation/concepts/rootfi-connect/invite-link), and provide a name for your customers' company. 2. A unique `company_id` will be generated once your customer completes the authentication flow. This `company_id` will be used to read and write data to their accounting platform. *** ## 2. Create a Bill (Recurring) Use [**POST/bills**](/api-reference/v4/unified/bills/overview) to create bills. Important points to note: 1. **Contacts**: This is the vendor linked to the Bill. Use [**GET/contacts**](/api-reference/v4/unified/contacts/overview) and [**POST/contacts**](/api-reference/v4/unified/contacts/overview). A Contact ID is required to post a Bill, so if the contact doesn't exist on the accounting platform, create a new vendor using [**POST/contacts**](/api-reference/v4/unified/contacts/overview). 2. **Expense Account or Debited Account**: You can push multiple line items (usually just 1) when pushing an bill. Each line item will have an expense account associated (category = 'expense'). [**GET/accounts**](/api-reference/v4/unified/accounts/overview) lets you fetch all accounts, and you can filter the account type by **category = 'expense'**. 3. **Purchase Order**: Most companies usually issue Purchase Orders before a bill is generated. The Purchase Order ID can be passed in [**POST/bills**](/api-reference/v4/unified/bills/overview) to link the purchase order and bill. 4. **Credit Account** (Not Required): When you use [**POST/bills**](/api-reference/v4/unified/bills/overview), bills are automatically placed under the Account - **category = 'liability'** and **account\_type = 'accounts\_payable'**. *** ## 3. Upload Documents (Recurring) [**POST/documents**](/api-reference/v4/unified/documents/overview) lets you upload a file to an expense, invoice, or bill. When posting a document you will be required to pass the field `document_type_id`, which represents the `platform_id` that will be returned after you create a bill. *** ## 4. Link Bill Payment and Credit Notes A Bill Payment credits an account that serves as the source of funds for the payment (Credit Card or Bank). 1. Use [**POST/bill\_payments**](/api-reference/v4/unified/bill_payments/overview) to create and link bill payments. The bill credit note can be created and immediately applied to a bill, or it can be created and left unapplied. 1. Use [**POST/bill\_credit\_notes**](/api-reference/v4/unified/bill_credit_notes/overview) to create a Bill Credit note, which can be linked to a Vendor. *** ## Learn how to build an Automated Accounts Payable (AP) product The steps above explain how to manage the most common actions of an automated Accounts Payable (AP) product with RootFi' accounting integrations. If you have more questions or would like to build an automated Accounts Payable (AP) product with RootFi' Unified APIs, we'd love to help you get started. Speak to our integration experts today! *** # Accounts Receivable (AR) Source: https://integrations.docs.commenda.io/guides/accounts-receivable This guide helps Accounts Receivable companies automate the creation and reconciliation of invoices, invoice payments, invoice credit notes, and sales orders with their customers' respective accounting systems. *** ## Introduction Accounting integrations play a pivotal role in bridging your automated Accounts Receivable (AR) solution with your customers' accounting systems. This document is a step-by-step guide that details the process of using accounting integrations (via RootFi' Unified Accounting API) to develop an automated Accounts Receivable (AR) product with reconciliation. *** ## What is the Accounts Receivable (AR) Workflow? The AR workflow involves the following key steps: 1. **Invoice Generation**: Automatically create and send invoices based on services rendered or products sold. 2. **Payment Tracking**: Monitor incoming payments and match them against outstanding invoices. 3. **Reminders and Collections**: Send automated reminders for overdue invoices and manage collections for delinquent accounts. 4. **Reconciliation**: Ensure payments are accurately reflected in the accounting system. Integrating with accounting systems is vital for automating these processes, ensuring that both invoices and payments are processed and reconciled accurately. *** ## The Role of Accounting Integrations and RootFi' Unified Accounting API Building and maintaining integrations with various accounting platforms in-house can be a daunting task - the time and expert resources required come at a high cost. RootFi' Unified API provides a more efficient solution by offering: * **Broad Connectivity**: Access to multiple accounting platforms, ensuring comprehensive coverage for all current and future customers. * **Accelerated Go-to-Market**: Integrating once with a Unified API significantly reduces the time and effort needed to test, launch, and scale an integrated solution. * **Cost Reduction**: Using RootFi eliminates the expenses associated with developing custom integrations. * **Ease of Maintenance**: Offloads integration maintenance responsibilities to RootFi, allowing your team to focus on core product enhancement. Leveraging RootFi' Unified API accelerates the development of your AR automation solution and enhances its reliability and value to customers, ensuring seamless integration with their preferred accounting platforms. *** ## How to Build an Automated Accounts Receivable (AR) Solution with a Unified Accounting API This step-by-step guide can help expense management companies use RootFi' Unified Accounting API to automate their customers' invoices, invoice payments, invoice credit notes, and sales orders reconciliation with their respective accounting systems. Handle all of the common workflows required to offer an Accounts Receivable/ Invoice Payment product to your customers. Here is a quick summary of all the steps involved: 1. Use RootFi' Auth Flow to connect a business customer's accounting system. 2. Use the Invoice API to create an Invoice and link Customers, Sales Orders, Items, and Accounts to the respective Invoice. 3. Upload Documents to their respective Invoice. 4. Create and Link Invoice Payments and Invoice Credit Notes to Customers and Open Invoices. *** ## 1. Connect with your customers' accounting platform (One-Time Activity) RootFi provides two convenient options to connect with your customers' accounting platform: 1. Use RootFi' **Connect Link**, a convenient and secure URL, **or** 2. Embed RootFi' **Connect SDK** into your application The Invite Link requires no code, making it suitable to get started without a developer. You can customize and white-label this onboarding process with RootFi' Connect SDK, allowing authentication to occur natively in your product. Either way, your customers will be guided through a simple authorization flow to connect their respective accounting platforms to your product. 1. Use our Dashboard or APIs to connect a customer's accounting platform. Use [**POST/invite-links**](/documentation/concepts/rootfi-connect/invite-link), and provide a name for your customers' company. 2. A unique `company_id` will be generated once your customer completes the authentication flow. This `company_id` will be used to read and write data to their accounting platform. *** ## 2. Create Invoices (Recurring) **POST/invoice** to create an invoice. Important points to note while trying to post an Invoice: 1. **Contacts**: This is the customer linked to the Invoice. Use [**GET/contacts**](/api-reference/v4/unified/contacts/overview) or [**POST/contacts**](/api-reference/v4/unified/contacts/overview). A `contact_id` is required to post an Invoice, so if the customer doesn't exist on the accounting platform, you'll first have to create a new customer using the [**POST/contacts**](/api-reference/v4/unified/contacts/overview). 2. **Items**: Every invoice contains multiple items (either goods or services) that were sold as part of the invoice, each of which credits certain accounts depending on what comprises their cost of goods sold. [**GET/items**](/api-reference/v4/unified/items/overview) lets you fetch all items in the business entity's catalogue. 3. **Sales/Purchase Order**: Some companies issue Sales or Purchase Orders before an Invoice is generated. Use [**GET/sales\_orders**](/api-reference/v4/unified/sales_orders/overview) to get the Sales Order ID, which can be passed in [**POST/invoices**](/api-reference/v4/unified/invoices/overview) to link the purchase order and bill. 4. **Credit Account** (Not Required): When you use the [**POST/invoices**](/api-reference/v4/unified/invoices/overview), invoices are automatically placed under **account category = 'asset'** and **account type = 'accounts\_receivable'**. *** ## 3. Upload Documents (Recurring) [**POST/documents**](/api-reference/v4/unified/documents/overview) lets you upload a file to an expense, invoice, or bill. When posting a document you will be required to pass the feild `document_type_id`, which represents the `platform_id` that will be returned after you create a Invoice. *** ## 4. (Recurring): Link Invoice Payment and Credit Notes An Invoice Payment debits an accounts receivable account and credits an asset account. 1. Use [**POST/invoice\_payments**](/api-reference/v4/unified/invoice_payments/overview) to create and link Invoice payments. The Invoice Credit Note can be created and immediately applied to a bill, or it can be created and left unapplied. 1. An Invoice Credit Note can be created using the [**POST/invoice\_credit\_notes**](/api-reference/v4/unified/invoice_credit_notes/overview) and is linked to a Customer. *** ## Learn how to build an Automated Accounts Receivable (AR) product The steps above explain how to manage the most common actions of an automated Accounts Receivable (AR) product with RootFi' accounting integrations. If you have more questions or would like to build an automated Accounts Receivable (AR) product with RootFi' Unified APIs, we'd love to help you get started. Speak to our integration experts today! *** # Expense Management Source: https://integrations.docs.commenda.io/guides/expense-management Automate your customers' expense reconciliation with their respective accounting systems. *** ## Introduction This comprehensive guide is designed to help Expense Management companies automate their customers' expense reconciliation with their respective accounting systems using RootFi' Unified Accounting API. *** ## Need for Accounting Integrations Automation transforms how your expense management product handles your business customers' expenses by simplifying the expense collection, verification, and approval process. The challenge arises when you need to connect to different customers' accounting platforms to automate expense reconciliation. Accounting integrations bridge the data gap between your product and your customers' accounting systems. While these integrations are crucial, building and maintaining multiple integrations in-house is time-consuming, expensive, and resource-intensive. *** ## Benefits of RootFi' Unified Accounting API RootFi' Unified API offers a more efficient approach by allowing you to leverage one API to integrate with multiple accounting platforms. The benefits include: 1. **Global Connectivity**: Simplifies integration with multiple accounting platforms, ensuring maximum coverage for current and future customers. 2. **Accelerated Go-to-Market**: Integrating with one Unified API significantly cuts down the time required to build, test, and launch an integrated product. 3. **Cost Savings**: Lowers the overall cost of developing and maintaining integrations, allowing resources to focus on core product development. 4. **Maintenance Ease**: Offloads integration maintenance responsibilities, allowing your team to focus on core product enhancement. Partnering with RootFi can accelerate your time to market and enhance your product's value to your customers, thereby increasing customer satisfaction, product appeal, and revenue potential. *** This workflow can be used for the following types of accounts: * Pre-Paid Cards * Credit Cards * Debit Cards *** ## 1. Connect with your customers' accounting platform (One-Time Activity) RootFi provides two convenient options to connect with your customers’ accounting platform: Use RootFi’ Connect Link, a convenient and secure URL, **or** Embed RootFi’ Connect SDK into your application The Invite Link requires no code to use, making it suitable to get started without a developer. You can customize and white-label this onboarding process with RootFi’ Connect SDK, allowing authentication to occur natively in your product. Either way, your customers will be guided through a simple authorization flow to connect their respective accounting platforms to your product. Use our Dashboard or APIs to connect a customer’s accounting platform a. Use the POST/invite-link. b. Name your customers’ company. A unique `company_id` will be generated once your customer completes the authentication flow. This `company_id` will be used to read and write data to their accounting platform. *** ## 2. Link or Create your customer's credit card or bank account (One-Time Activity) Every expense transaction must have an **Account** as a source of funds that is credited. > [tab] For Pre-Paid / Debit Cards > > This is a Bank Account with a **category = 'Bank'** > > 1. Use [GET/bank\_accounts](/api-reference/v4/unified/bank-accounts/overview) to get the **Bank Account ID** if the account already exists in the customer's accounting platform, **or** > 2. Use [POST/bank\_accounts](/api-reference/v4/unified/bank-accounts/overview) to create a bank account and get the **Bank Account ID**. > [tab] For Credit / Debit Cards > > This is an Account with a **category = 'Liability'** > > 1. Use [GET/accounts](/api-reference/v4/unified/accounts/overview) to get the **Account ID** if the account already exists in the customer's accounting platform. > **OR** > 2. Use [POST/accounts](/api-reference/v4/unified/accounts/overview) to create an Account and get the **Account ID**. *** ## 3. Create Expenses (Recurring) Generally, use the [POST/expenses](/api-reference/v4/unified/expenses/overview) to create expenses. > [!NOTE] > > If Expenses are unavailable for a particular accounting platform like Xero and Tally, use the [POST/bills](/api-reference/v4/unified/bills/overview) or [POST/journal\_entries](/api-reference/v4/unified/journal_entries/overview). Essential points to note: 1. **Credit Account**: The account from which funds are drawn. Refer to Step 2 for more information. 2. **Vendor**: The employee linked to the expense. Use the [GET/contacts](/api-reference/v4/unified/contacts/overview) and [POST/contacts](/api-reference/v4/unified/contacts/overview) and filter on type = `vendor`. A **Contact ID** is required to post an Expense or Bill. If the employee doesn't exist on the accounting platform, create a new vendor using the [POST/contacts](/api-reference/v4/unified/contacts/overview). 3. **Expense Account or Debited Account**: You can push multiple line items (usually just 1) when pushing an expense. Each line item will have an expense **account** associated (category = `expense`). Use the [GET/accounts](/api-reference/v4/unified/accounts/overview) to fetch all accounts, and filter the account type by **category = `expense`** using the `category` filter. *** ## 4. Upload Documents (Recurring) Use the [POST/documents](/api-reference/v4/unified/documents/overview) to upload and attach files from a customer's employee to an expense, invoice, or bill. *** ## 5. Record a Credit Card Repayment (Recurring) Use the [POST/journal\_entries](/api-reference/v4/unified/journal_entries/overview) to reflect a credit card repayment. 1. **Credited Account**: The bank account used to make the repayment. 2. **Contact**: In this case, it will be the expense management company (your company). 3. **Debited Account**: The credit card liability account. *** ## 6. Process Bank Account Withdrawals or Top Ups for Pre-Paid Cards (Recurring) Use [POST/journal\_entries](/api-reference/v4/unified/journal_entries/overview) to reflect withdrawals and top-ups for a bank account/prepaid card. 1. **Credited Account**: The bank account used to make the top-up. 2. **Debited Account**: The account being topped up (pre-paid asset or bank account). *** ## 7. Process Employee Reimbursement Requests and Payments (Recurring) Employee reimbursement requests and reimbursement payments are reflected in the accounting system as **Bills** and **Bill Payments**. 1. To log a reimbursement request, use [POST/bills](/api-reference/v4/unified/bills/overview) to create a bill containing the reimbursement amount. * Use [POST/contacts](/api-reference/v4/unified/contacts/overview) (filter on type = 'vendor') to create a specific vendor per employee you link to the Bill. 2. Once the reimbursement is approved and the payment is made, use the [POST/bill\_payments](/api-reference/v4/unified/bill_payments/overview) to log a payment against the requested reimbursement. *** ## Conclusion This detailed guide outlines how to manage the most common actions of an expense management product with RootFi' accounting integrations. If you have more questions or would like to build an automated expense management product with RootFi' Unified APIs, contact RootFi' integration experts for assistance in getting started. *** # Payroll Source: https://integrations.docs.commenda.io/guides/payroll Sync processed payrolls with your customers' respective accounting systems. *** ## Introduction This comprehensive guide is designed to help HR and Payroll companies reconcile processed payrolls to their customers' respective accounting systems using RootFi' Unified Accounting API. Here is a quick summary of all the steps involved: 1. Use RootFi' **authentication flow to connect** to each business customer's accounting system. 2. Categorize and **map** payroll components. 3. **Sync** processed payroll with your customer's accounting software. *** ## 1. Connect with your customers' accounting platform (One-Time Activity) RootFi provides two convenient options to connect with your customers' accounting platform: 1. Use RootFi' **Connect Link**, a convenient and secure URL, or 2. Embed RootFi' **Connect SDK** into your application The Invite Link requires no code, making it suitable to get started without a developer. You can customize and white-label this onboarding process with RootFi' Connect SDK, allowing authentication to occur natively in your product. Either way, your customers will be guided through a simple authorization flow to connect their respective accounting platforms to your product. 1. Use our Dashboard or APIs to connect a customer's accounting platform. Use the [**POST /v4/core/invite-links**](/documentation/concepts/rootfi-connect/invite-link) API, and provide a name for your customers' company. 2. A unique `company_id` will be generated once your customer completes the authentication flow. This `company_id` will be used to read and write data to their accounting platform. *** ## 2. Categorize and map payroll components For your customers to appropriately represent their payroll costs in their accounting software, they will need to do some initial configuration. Typically, each customer will want to set the following: * Which bank account payments are made from * Which expense account does each payroll component correspond with * Any additional mapping for things like tracking categories ### 2.1 Make customers select the Bank account where payroll will be processed from You must guide your customer to link the Bank Account from which payroll is dispersed. You should create a front-end that allows your customers to select the appropriate Bank Account. To have your front-end populate the available Banks Accounts from their underlying accounting platform, call [GET/accounts](/api-reference/v4/unified/accounts/overview) and filter by **type = 'bank'** or call [GET/bank\_accounts](/api-reference/v4/unified/bank-accounts/overview). ### 2.2 Make customers select which Expense Account each Payroll component corresponds with Each customer will have different preferences for recording payroll costs, pensions, and employee taxes against various nominal accounts. **Your system should have a list of payroll components representing the different parts of a company's payroll.** To meet your customers' needs, it is important to offer a flexible interface that allows companies to handle the nuances of data reconciliation according to their preferences. The mapping process can be as complex or granular as required for your specific use case. To have your interface populate the available Expense Accounts from their underlying accounting platform, use [GET/accounts](/api-reference/v4/unified/accounts/overview). ### 2.3 Allow for Additional Categorization using Tracking Categories Businesses may require additional categorization for their payroll expenses. For instance, they may want to group expenses by department (e.g., sales and marketing) or location. Our [GET/tracking\_categories](/api-reference/v4/unified/tracking-categories/overview) can retrieve each company's departments, locations, and projects. *** ## 3. Sync Processed Payroll with Accounting Software Before recording the payroll in your customers' accounting platform, you must generate a line item object for each employee for each corresponding payroll component. This means you'll likely have multiple line items for each employee. To record payroll entries to the mapped accounts in your customers' accounting platform, use [POST/journal\_entries](/api-reference/v4/unified/journal_entries/overview). When creating the payroll Journal Entry, you should create a line item for each payroll component. > [!NOTE] > > The sum of the amounts on the payroll component must equal the sum of the debit on the mapped bank account from which the payment is being made. Here are three examples: ### Journal Entry Example #1 Say your customer has one employee on their payroll. Your first entry shows the employee's gross wages, payroll taxes withheld, deductions, and net pay. It includes the following: * Gross wages * Employee Income tax payable * Employee health insurance payable * Payroll payable (aka the employee's net wages) Gross wages are an expense that increases with a debit. The rest of the accounts are liabilities. Credit your liabilities. Here's how the first journal entry would look: | Date | Account | Debit | Credit | | - | - | - | - | | XX/XX/XXXX | Salaries and Employee Wages | 1,000 | | | | Employee Income Tax Payable | | 80 | | | Employee Health Insurance Payable | | 20 | | | Payroll Payable | | 900 | > [!NOTE] > > Remember that your debits (left side) should equal your credits (right side). Double-check your totals and look for accounting mistakes if they don't balance. ### Journal Entry Example #2 Make a second journal entry when the customer gives their employee their paycheck. When they pay the employee, they no longer owe wages, so their liabilities decrease and their bank account decreases because they paid their employee. Because it's a liability, decrease the Payroll Payable account with a debit. And decrease the Cash account (an asset) with a credit. > [!NOTE] > > For Xero, please use the bank transactions data model to post this entry. | Date | Account | Debit | Credit | | - | - | - | - | | XX/XX/XXXX | Payroll Payable | 900 | | | | Bank Account | | 900 | ### Journal Entry Example #3 Eventually, your customer will need to pay employer taxes and remit withheld taxes. This is where a third accounting entry for payroll comes in. Reverse the payable entries with a debit and decrease your bank account with a credit. The amount you credit your cash account is the total amount you must remit for federal and state taxes. For Xero, please use the bank transactions data model to post this entry. | Date | Account | Debit | Credit | | - | - | - | - | | XX/XX/XXXX | Employee Tax Payable | 80 | | | | Employee Health Insurance Payable | 25 | | | | Bank Account | | 100 | *** ## Conclusion Once you've completed the steps described above, you can automatically sync processed payrolls to your customers' respective accounting systems. Feel free to contact us if you have any questions; we're always happy to help. *** # Point-Of-Sale (POS) Source: https://integrations.docs.commenda.io/guides/pos This guide helps Point-Of-Sale (POS) companies to push merchants' data from their e-commerce or point-of-sale (POS) platform into thier merchant's accounting platform. *** ## Introduction RootFi allows you to push merchants' data from your e-commerce or point-of-sale (POS) platform into your merchant's accounting platform. Your merchants can seamlessly reconcile their transaction data into their accounting software, allowing them to spend more time growing their business. This workflow can be used for the following types of Companies: * POS * Vertical SaaS * Payments Companies * E-Commerce Companies *** ## Overview RootFi APIs enable you to handle all the common workflows required to automate your business customers' payment data from your POS/e-commerce solution. Through RootFi, your merchant can choose to reflect their sales data from e-commerce and point-of-sale (POS) software: * As an aggregated daily/weekly **sales invoice**, or * As an aggregated daily/weekly **journal entry** RootFi recommends using **journal entries** due to the following advantages: * **Ease of use:** Single daily journal entries are easier to manage, adjust, and reconcile than, for example, invoices, payments, and credit notes. * **Controlled impact on the general ledger:** A journal entry is the most granular way to impact a company's general ledger without being confined to specific account types. * **Platform API Coverage:** Journal Entries are the most widely supported data model across all accounting platforms. Other Data Models, such as Invoice Payments, Expenses, and Credit Notes, may not be available. *** ## Getting Started Here's a summary of the steps involved to get started: 1. **Accounting Platform selection:** Use RootFi' Auth Flow to connect a business customer's accounting system. 2. **Merchant Configuration:** Once the Merchant provides access to the accounting platform, the merchant must set how the synchronization should work. This will tell you how the data should be mapped to the accounting platform. *** ## 1. Accounting Platform Selection RootFi provides two convenient options to connect with your customers' accounting platform: 1. Use RootFi' **Connect Link**, a convenient and secure URL, **or** 2. Embed RootFi' **Connect SDK** into your application The Invite Link requires no code, making it suitable to get started without a developer. You can customize and white-label this onboarding process with RootFi' Connect SDK, allowing authentication to occur natively in your product. Either way, your customers will be guided through a simple authorization flow to connect their respective accounting platforms to your product. 1. Use our Dashboard or APIs to connect a customer's accounting platform. Use the [**POST /v4/core/invite-links**](/documentation/concepts/rootfi-connect/invite-link) API, and provide a name for your customers' company. 2. A unique `company_id` will be generated once your customer completes the authentication flow. This `company_id` will be used to read and write data to their accounting platform. *** ## 2. Merchant Configuration This section provides guidelines for data mapping configuration from a POS/commerce platform to the supported accounting platforms (Netsuite, Xero, QuickBooks online). In RootFi' POS workflow, the data types are grouped under four main features: * Sales * Fees * Taxes * Payments **You will need to create a UI for this step.** Request your Merchant to Map the following features to the respective General Ledger accounts from their accounting platform: **Sales Account Mapping** 1. Sales (Revenue/Income Account) 2. Refunds (Revenue/Income Account) 3. Gratuity/Tips (Liability) 4. Prepaid Cards (Liability Account) **Payment Fees Account Mapping** 1. Processing Fees (Platform Fee/ Expense Account) 2. Processing Fees Refund (Platform Fee Refund/ Expense Account) **Tax Account Mapping (Optional)** **Payment Account Mapping** * Card (Accounts receivable) * Cash (Cash/Bank) * Payouts (accounts receivable) To get the General Ledger Account Names and IDs: 1. Use the **GET/Accounts APIs** to get the **Account ID and Name** if the account already exists in the customer's accounting platform. 2. Use the **POST/Accounts APIs** to create a GL account if it does not exist > [!NOTE] > > Store this mapping internally to post Journal Entries accurately. *** ## Posting Aggregated Daily/Weekly Journal Entries A Journal Entry can be mapped to any General Ledger Account. 1. Use the [**POST /v4/core/companies//journal\_entries**](/api-reference/v4/unified/journal_entries/overview) Data Model to create a journal entry in your Merchants Accounting Platform. 2. Use the Account IDs Mapped above to push Journal Entries to their respective Accounts. ### Example: Daily aggregated sales journal entry This example journal entry covers a sales total of $1000, tax total of$ 200, gratuities of $50, and payment processing fee of$ 50. And A payout from the POS company. | Accounts | Account Type | Debit | Credit | | - | - | - | - | | Accounts Receivable | Asset | \$1,200 | | | Revenue/Sales | Income | | \$1,000 | | Gratuities | Income or Liability | | \$50 | | Sales Tax | Liability | | \$200 | | Processing Fee | Expense | \$50 | | | Accounts | Account Type | Debit | Credit | | - | - | - | - | | Accounts Receivable | Asset | | \$1200 | | Bank Account | Asset | \$1200 | | *** ## Posting Sales Invoice Method Sales are booked on a nominal account of the type **Income**. This is the account that the merchant would typically use to book their sales. The merchant can select an existing account from the accounting platform. If an account is unavailable, it must be created in the accounting platform for this purpose. 1. RootFi pushes a single sales invoice to the Accounting platform daily. This invoice represents all sales made over that day. * The invoice is issued to the commerce services provider. * The invoice contains one line item for each tax rate the merchant trades in, with this line item representing the total of all sales at that tax rate. 2. When the merchant receives payment for the reported sales, the invoice is marked as paid and balanced against an invoice payment. *** ## Conclusion This guide outlines the process of using RootFi for POS Accounting Automation. It covers the essential steps of connecting to accounting platforms, configuring merchant settings, and posting journal entries or sales invoices. By following these steps, you can enable your merchants to seamlessly reconcile their e-commerce and accounting data, allowing them to focus on growing their business. *** # Create a bill Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-bill /openapi_v4_core.json post /v4/core/companies/{companyId}/bills # Create a budget Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-budget /openapi_v4_core.json post /v4/core/companies/{companyId}/budgets # Create a cash sale Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-cash-sale /openapi_v4_core.json post /v4/core/companies/{companyId}/cash_sales # Create a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-contact /openapi_v4_core.json post /v4/core/companies/{companyId}/contacts # Create a journal entry Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-journal-entry /openapi_v4_core.json post /v4/core/companies/{companyId}/journal_entries # Create a project Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-project /openapi_v4_core.json post /v4/core/companies/{companyId}/projects # Create a purchase order Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-purchase-order /openapi_v4_core.json post /v4/core/companies/{companyId}/purchase_orders # Create a sales order Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-sales-order /openapi_v4_core.json post /v4/core/companies/{companyId}/sales_orders # Create a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-subscription /openapi_v4_core.json post /v4/core/companies/{companyId}/subscriptions # Create an estimate Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-estimate /openapi_v4_core.json post /v4/core/companies/{companyId}/estimates # Create an expense Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-expense /openapi_v4_core.json post /v4/core/companies/{companyId}/expenses # Create an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-invoice /openapi_v4_core.json post /v4/core/companies/{companyId}/invoices # Create an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-invoice-credit-note /openapi_v4_core.json post /v4/core/companies/{companyId}/invoice_credit_notes # Create an invoice payment Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-invoice-payment /openapi_v4_core.json post /v4/core/companies/{companyId}/invoice_payments # Create an item Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-item /openapi_v4_core.json post /v4/core/companies/{companyId}/items # Get a bill Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-bill /openapi_v4_core.json get /v4/core/companies/{companyId}/bills/{id} # Get a budget Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-budget /openapi_v4_core.json get /v4/core/companies/{companyId}/budgets/{id} # Get a cash flow statement Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-cash-flow-statement /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_flow_statements/{id} # Get a cash refund Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-cash-refund /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_refunds/{id} # Get a cash sale Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-cash-sale /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_sales/{id} # Get a company info Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-company-info /openapi_v4_core.json get /v4/core/companies/{companyId}/company_info/{id} # Get a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-contact /openapi_v4_core.json get /v4/core/companies/{companyId}/contacts/{id} # Get a currency Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-currency /openapi_v4_core.json get /v4/core/companies/{companyId}/currencies/{id} # Get a document Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-document /openapi_v4_core.json get /v4/core/companies/{companyId}/documents/{id} # Get a goods receipt note Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-goods-receipt-note /openapi_v4_core.json get /v4/core/companies/{companyId}/goods_receipt_notes/{id} # Get a journal entry Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-journal-entry /openapi_v4_core.json get /v4/core/companies/{companyId}/journal_entries/{id} # Get a line item Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-line-item /openapi_v4_core.json get /v4/core/companies/{companyId}/line_item/{id} # Get a project Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-project /openapi_v4_core.json get /v4/core/companies/{companyId}/projects/{id} # Get a purchase order Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-purchase-order /openapi_v4_core.json get /v4/core/companies/{companyId}/purchase_orders/{id} # Get a sales order Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-sales-order /openapi_v4_core.json get /v4/core/companies/{companyId}/sales_orders/{id} # Get a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-subscription /openapi_v4_core.json get /v4/core/companies/{companyId}/subscriptions/{id} # Get an estimate Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-estimate /openapi_v4_core.json get /v4/core/companies/{companyId}/estimates/{id} # Get an expense Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-expense /openapi_v4_core.json get /v4/core/companies/{companyId}/expenses/{id} # Get an income statement Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-income-statement /openapi_v4_core.json get /v4/core/companies/{companyId}/income_statements/{id} # Get an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-invoice /openapi_v4_core.json get /v4/core/companies/{companyId}/invoices/{id} # Get an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-invoice-credit-note /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_credit_notes/{id} # Get an invoice payment Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-invoice-payment /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_payments/{id} # Get an item Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-item /openapi_v4_core.json get /v4/core/companies/{companyId}/items/{id} # List budgets Source: https://integrations.docs.commenda.io/api-reference/accounting/list-budgets /openapi_v4_core.json get /v4/core/companies/{companyId}/budgets # List cash flow statements Source: https://integrations.docs.commenda.io/api-reference/accounting/list-cash-flow-statements /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_flow_statements # List cash refunds Source: https://integrations.docs.commenda.io/api-reference/accounting/list-cash-refunds /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_refunds # List cash sales Source: https://integrations.docs.commenda.io/api-reference/accounting/list-cash-sales /openapi_v4_core.json get /v4/core/companies/{companyId}/cash_sales # List company info Source: https://integrations.docs.commenda.io/api-reference/accounting/list-company-info /openapi_v4_core.json get /v4/core/companies/{companyId}/company_info # List contacts Source: https://integrations.docs.commenda.io/api-reference/accounting/list-contacts /openapi_v4_core.json get /v4/core/companies/{companyId}/contacts # List currencies Source: https://integrations.docs.commenda.io/api-reference/accounting/list-currencies /openapi_v4_core.json get /v4/core/companies/{companyId}/currencies # List documents Source: https://integrations.docs.commenda.io/api-reference/accounting/list-documents /openapi_v4_core.json get /v4/core/companies/{companyId}/documents # List estimates Source: https://integrations.docs.commenda.io/api-reference/accounting/list-estimates /openapi_v4_core.json get /v4/core/companies/{companyId}/estimates # List expenses Source: https://integrations.docs.commenda.io/api-reference/accounting/list-expenses /openapi_v4_core.json get /v4/core/companies/{companyId}/expenses # List goods receipt notes Source: https://integrations.docs.commenda.io/api-reference/accounting/list-goods-receipt-notes /openapi_v4_core.json get /v4/core/companies/{companyId}/goods_receipt_notes # List income statements Source: https://integrations.docs.commenda.io/api-reference/accounting/list-income-statements /openapi_v4_core.json get /v4/core/companies/{companyId}/income_statements # List invoice credit notes Source: https://integrations.docs.commenda.io/api-reference/accounting/list-invoice-credit-notes /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_credit_notes # List invoice payments Source: https://integrations.docs.commenda.io/api-reference/accounting/list-invoice-payments /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_payments # List invoices Source: https://integrations.docs.commenda.io/api-reference/accounting/list-invoices /openapi_v4_core.json get /v4/core/companies/{companyId}/invoices # List items Source: https://integrations.docs.commenda.io/api-reference/accounting/list-items /openapi_v4_core.json get /v4/core/companies/{companyId}/items # List journal entries Source: https://integrations.docs.commenda.io/api-reference/accounting/list-journal-entries /openapi_v4_core.json get /v4/core/companies/{companyId}/journal_entries # List line item Source: https://integrations.docs.commenda.io/api-reference/accounting/list-line-item /openapi_v4_core.json get /v4/core/companies/{companyId}/line_item # List projects Source: https://integrations.docs.commenda.io/api-reference/accounting/list-projects /openapi_v4_core.json get /v4/core/companies/{companyId}/projects # List purchase orders Source: https://integrations.docs.commenda.io/api-reference/accounting/list-purchase-orders /openapi_v4_core.json get /v4/core/companies/{companyId}/purchase_orders # List sales orders Source: https://integrations.docs.commenda.io/api-reference/accounting/list-sales-orders /openapi_v4_core.json get /v4/core/companies/{companyId}/sales_orders # List subscriptions Source: https://integrations.docs.commenda.io/api-reference/accounting/list-subscriptions /openapi_v4_core.json get /v4/core/companies/{companyId}/subscriptions # List tax rates Source: https://integrations.docs.commenda.io/api-reference/accounting/list-tax-rates /openapi_v4_core.json get /v4/core/companies/{companyId}/tax_rates # Update a bill Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-bill /openapi_v4_core.json put /v4/core/companies/{companyId}/bills # Update a budget Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-budget /openapi_v4_core.json put /v4/core/companies/{companyId}/budgets # Update a cash sale Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-cash-sale /openapi_v4_core.json put /v4/core/companies/{companyId}/cash_sales # Update a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-contact /openapi_v4_core.json put /v4/core/companies/{companyId}/contacts # Update a journal entry Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-journal-entry /openapi_v4_core.json put /v4/core/companies/{companyId}/journal_entries # Update a project Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-project /openapi_v4_core.json put /v4/core/companies/{companyId}/projects # Update a purchase order Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-purchase-order /openapi_v4_core.json put /v4/core/companies/{companyId}/purchase_orders # Update a sales order Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-sales-order /openapi_v4_core.json put /v4/core/companies/{companyId}/sales_orders # Update a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-subscription /openapi_v4_core.json put /v4/core/companies/{companyId}/subscriptions # Update an estimate Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-estimate /openapi_v4_core.json put /v4/core/companies/{companyId}/estimates # Update an expense Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-expense /openapi_v4_core.json put /v4/core/companies/{companyId}/expenses # Update an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-invoice /openapi_v4_core.json put /v4/core/companies/{companyId}/invoices # Update an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-invoice-credit-note /openapi_v4_core.json put /v4/core/companies/{companyId}/invoice_credit_notes # Update an invoice payment Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-invoice-payment /openapi_v4_core.json put /v4/core/companies/{companyId}/invoice_payments # Update an item Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-item /openapi_v4_core.json put /v4/core/companies/{companyId}/items # Post v4corecompanies documents Source: https://integrations.docs.commenda.io/api-reference/documentwrite/post-v4corecompanies-documents /openapi_v4_core.json post /v4/core/companies/{companyId}/documents # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/budgets/overview A Budget is a planned allocation of amounts across accounts, projects, or items for a defined period. **The Budgets Data Model** represents a planned allocation of amounts for a defined period, broken down into budget lines against accounts, projects, items, or tracking categories. This unified model standardises budget information across accounting platforms. * **Unified budget properties**: Essential budget details, such as name, type, status, currency, and the start and end dates of the budget period, are standardised across different accounting platforms * **Budget lines**: The `budget_lines` property includes an array of related budget lines, each carrying the amount planned for one account, project, or item on a given date ## Attributes ### Budgets Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this budget | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this budget in the source accounting platform | | `name` | string | The name of the budget | | `budget_type` | enum | The type of the budget | | `status` | enum | The status of the budget | | `currency_id` | enum | ISO 4217 currency code | | `start_date` | string | The first day of the budget period | | `end_date` | string | The last day of the budget period | | `updated_at` | string | The date and time the budget was last updated | ### Budget Type Enum Values | Value | Description | | - | - | | `PROJECT` | Budget is planned against a project | | `GENERAL_LEDGER` | Budget is planned against general ledger accounts | | `UNKNOWN` | Budget type could not be determined | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Budget is in use | | `ARCHIVED` | Budget is no longer in use | | `UNKNOWN` | Budget status could not be determined | ### Budget Lines Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this budget line | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this budget line in the source accounting platform | | `budget_id` | string | The budget this line belongs to | | `account_id` | string | The account the line is planned against | | `project_id` | string | The project the line is planned against | | `item_id` | string | The item the line is planned against | | `tracking_category_ids` | array | Tracking categories applied to the line | | `description` | string | The description of the budget line | | `quantity` | double | The planned quantity | | `unit_amount` | double | The planned amount per unit | | `total_amount` | double | The planned total amount | | `date` | string | The date the line is planned for | | `updated_at` | string | The date and time the budget line was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=budget_lines` — includes the related Budget Lines object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this budget in the source accounting platform | | `name` | string | The name of the budget | | `budget_type` | enum | The type of the budget | | `status` | enum | The status of the budget | | `currency_id` | enum | ISO 4217 currency code | | `start_date` | string | The first day of the budget period | | `end_date` | string | The last day of the budget period | | `updated_at` | string | The date and time the budget was last updated | | `budget_lines` | array | Budget lines to create or update with the budget | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/cash_flow_statements/overview Cash flow statements are financial statements that show the inflow and outflow of cash and cash equivalents from a company's operations, investments, and financing activities over a specific period of time. The Cash Flow Statements Data Model represents financial statements that show the inflow and outflow of cash and cash equivalents from a company's operations, investments, and financing activities over a specific period of time. * **Unified cash flow statement properties**: Essential cash flow statement details, such as period dates, cash balances, and activity line items, are standardized across different accounting platforms * **Hierarchical line item structure**: The model supports nested line items for operating, investing, and financing activities, enabling detailed breakdowns of cash flow * **Automatic generation**: Cash flow statements are typically generated automatically based on recorded financial transactions ## Attributes ### Cash Flow Statements Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this cash flow statement | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this cash flow statement in the source accounting platform | | `operating_activities` | object | The line items for operating activities of the cash flow statement report | | `investing_activities` | object | The line items for investing activities of the cash flow statement report | | `financing_activities` | object | The line items for financing activities of the cash flow statement report | | `cash_at_beginning_of_period` | double | The total amount at the beginning of the period | | `cash_at_end_of_period` | double | The total amount at the end of the period | | `period_start` | string | The start date of the cash flow statement report period | | `period_end` | string | The end date of the cash flow statement report period | | `updated_at` | string | The date and time the cash flow statement was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/cash_refunds/overview Cash refund records from connected accounting platforms. Cash refunds represent refund transactions recorded in accounting systems. Use this model to list refund documents with amounts, contacts, and line items (via `expand`). ## Attributes ### Cash Refunds Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `platform_id` | string | | | `platform_unique_id` | string | | | `posted_date` | string | | | `document_number` | string | | | `contact_id` | string | | | `total_discount` | double | | | `sub_total` | double | | | `tax_amount` | double | | | `total_amount` | double | | | `currency_id` | enum | | | `memo` | string | | | `shipping_amount` | double | | | `currency_rate` | double | | | `rootfi_integration_type` | enum | | | `status` | enum | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/cash_sales/overview Cash sale records from connected accounting platforms. **Cash sales** represent cash-sale transactions in accounting systems. Use this model to list sale documents with totals, status, and related line items (via `expand`). ## Attributes ### Cash Sales Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `platform_id` | string | | | `platform_unique_id` | string | | | `document_number` | string | | | `posted_date` | string | | | `currency_id` | enum | | | `total_discount` | double | | | `sub_total` | double | | | `tax_amount` | double | | | `total_amount` | double | | | `memo` | string | | | `shipping_amount` | double | | | `rootfi_integration_type` | enum | | | `status` | enum | | | `currency_rate` | double | | | `contact_id` | string | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/company-info/overview The Company Info Data Model is designed to simplify the management and retrieval of company-related information across various accounting platforms. **The Company Info Data Model** represents company-related information from various accounting platforms. This unified model simplifies the management and retrieval of company details. * **Unified company properties**: Essential company details, such as name, legal name, base currency, and registration number, are standardized across different accounting platforms * **Comprehensive contact information**: Retrieve company addresses, external links, and phone numbers for a complete view of company contacts * **Financial year tracking**: Monitor the company's financial year start date for accurate reporting and analysis ## Attributes ### Company Info Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this company info | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this company info in the source accounting platform | | `name` | string | The name of the company | | `legal_name` | string | The legal name of the company | | `tax_number` | string | The tax number of the company | | `registration_number` | string | The registration number of the company | | `base_currency` | string | The base currency of the company | | `fiscal_start_at` | string | The fiscal year start date of the company | | `org_created_at` | string | The date and time the organization was created | | `timezone` | string | | | `updated_at` | string | The date and time the company info was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=addresses` — includes the related Addresses object(s). * `expand=phone_numbers` — includes the related Phone Numbers object(s). * `expand=external_links` — includes the related External Links object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/contacts/overview A contact is an individual or company that buys or sells goods or services from a business. Commonly referred to as a customer on a corresponding invoice or a vendor for a bill. The Contacts Data Model represents an individual or company that buys or sells goods or services from a business. This unified model simplifies handling contact-related information across various accounting platforms. * **Unified contact properties**: Essential contact details like name, contact person, currency, and tax number are standardized across different accounting platforms * **Comprehensive contact information**: Contacts can include associated data like contact persons, phone numbers, addresses, and external links for a more detailed representation of each contact * **Status tracking**: The model supports tracking the status of each contact, with values like `ACTIVE`, `INACTIVE`, `SUSPENDED`, `ARCHIVED`, and `UNKNOWN`, facilitating better organisation and reporting ## Attributes ### Contacts Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this contact | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this contact in the source accounting platform | | `name` | string | The name of the contact | | `contact_name` | string | The name of the contact person for the contact | | `email` | string | | | `phone` | string | | | `tax_number` | string | The contact's tax number | | `type` | enum | The type of contact | | `status` | enum | The status of the contact | | `currency_id` | enum | The ISO-4217 currency code of the contact | | `registration_number` | string | The contact's identifying or registration number | | `website` | string | | | `created_at` | string | | | `updated_at` | string | The date and time the contact was last updated | ### Type Enum Values | Value | Description | | - | - | | `CUSTOMER` | Contact is a customer who receives invoices | | `VENDOR` | Contact is a vendor who provides bills | | `BOTH` | Contact acts as both customer and vendor | | `UNKNOWN` | Type cannot be determined from the platform | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Contact is active and in good standing | | `INACTIVE` | Contact has been voluntarily deactivated | | `SUSPENDED` | Contact is suspended due to payment/fraud issues | | `ARCHIVED` | Contact has been archived for record-keeping | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=addresses` — includes the related Addresses object(s). * `expand=phone_numbers` — includes the related Phone Numbers object(s). * `expand=external_links` — includes the related External Links object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this contact in the source accounting platform | | `name` | string | The name of the contact | | `contact_name` | string | The name of the contact person for the contact | | `email` | string | | | `phone` | string | | | `tax_number` | string | The contact's tax number | | `type` | enum | The type of contact | | `status` | enum | The status of the contact | | `currency_id` | enum | The ISO-4217 currency code of the contact | | `registration_number` | string | The contact's identifying or registration number | | `website` | string | | | `created_at` | string | | | `updated_at` | string | The date and time the contact was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/currencies/overview The Currencies Data Model streamlines access to currency information across various accounting platforms, providing a consistent and unified representation of currency data. The Currencies Data Model streamlines access to currency information across various accounting platforms, providing a consistent and unified representation of currency data. * **Multi-currency support**: Currencies enable businesses operating internationally to manage and track transactions in different national currencies * **Currency fluctuation insights**: By monitoring different currencies, businesses can gain critical insights into how currency fluctuations affect their financial performance * **Consolidated reporting**: Businesses can link different currency accounts or transactions to view consolidated reports in a single base currency ## Attributes ### Currencies Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this currency | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this currency in the source accounting platform | | `name` | string | The name of the currency | | `code` | string | The ISO-4217 currency code | | `symbol` | string | The symbol that represents the currency | | `is_base_currency` | boolean | Whether the currency is the base currency for the company | | `exchange_rate` | double | The exchange rate for the currency | | `updated_at` | string | The date and time the currency was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/documents/overview The Documents Data Model simplifies the handling of document documents across various accounting platforms, providing a standardised approach to accessing and managing document-related information. The Documents Data Model simplifies the handling of documents across various accounting platforms, providing a standardized approach to accessing and managing document-related information. * **Unified document properties**: Essential document details, such as file name, file type, file size, and platform ID, are standardized across different accounting platforms * **Document type association**: Documents can be linked to specific document types (e.g., bills, invoices, expenses) using the `document_type_id` and `document_type` properties, facilitating easy retrieval and organisation of documents * **File metadata**: The model includes file type (MIME Type) and file size properties, enabling developers to handle documents appropriately and ensure compatibility with their applications ## Attributes ### Documents Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this document | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this document in the source accounting platform | | `file_name` | string | The file name of the document | | `file_type` | string | The file type of the document (MIME Type) | | `file_size` | double | The file size of the document in bytes | | `document_type_id` | string | The document type ID of the document | | `document_type` | enum | The document type of the document | | `document_uploaded` | boolean | Whether RootFi has uploaded the document to its servers | | `updated_at` | string | The date and time the document was last updated | ### Document Type Enum Values | Value | Description | | - | - | | `BILL` | Document is associated with a bill | | `INVOICE` | Document is associated with an invoice | | `EXPENSE` | Document is associated with an expense | | `BILL_CREDIT_NOTE` | Document is associated with a bill credit note | | `INVOICE_CREDIT_NOTE` | Document is associated with an invoice credit note | | `PURCHASE_ORDER` | Document is associated with a purchase order | | `SALES_ORDER` | Document is associated with a sales order | | `JOURNAL_ENTRY` | Document is associated with a journal entry | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/estimates/overview The Estimates data model. The Estimate data model. ## Attributes ### Estimates Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `contact_id` | string | | | `currency_id` | enum | | | `currency_rate` | double | | | `document_number` | string | | | `posted_date` | string | | | `status` | enum | | | `memo` | string | | | `created_at` | string | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=contact` — includes the related Contact object(s). * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | | | `contact_id` | string | | | `currency_id` | enum | | | `currency_rate` | double | | | `document_number` | string | | | `posted_date` | string | | | `status` | enum | | | `memo` | string | | | `created_at` | string | | | `updated_at` | string | | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/expenses/overview Payment made by a business at the time of purchase (ex. a credit card payment). **The Expenses Data Model** represents a payment made by a business at the time of purchase. This unified model streamlines the management and retrieval of expense-related information across various accounting platforms. * **Unified expense properties**: Essential expense information, including document numbers, posted dates, payment modes, and currency details, are standardized across different accounting platforms * **Contact and account relationships**: Expenses can be easily linked to specific contacts and accounts using their respective platform IDs, allowing for efficient organisation and reporting * **Line item support**: The inclusion of line items within the expense data model enables more granular and detailed expense management, as well as the ability to track individual components of an expense * **Currency conversion**: The `currency_rate` property supports multi-currency scenarios by providing the conversion rate between the expense currency and the base currency, ensuring accurate financial reporting across various currencies ## Attributes ### Expenses Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this expense | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this expense in the source accounting platform | | `document_number` | string | The document number of the expense | | `currency_id` | enum | The ISO-4217 currency code of the expense | | `currency_rate` | double | The currency rate of the expense | | `memo` | string | The memo or notes of the expense | | `account_id` | string | The account ID of the expense | | `payment_mode` | string | The payment mode of the expense | | `posted_date` | string | The posted date of the expense | | `sub_total` | double | The sub total of the expense | | `tax_amount` | double | The tax amount of the expense | | `total_discount` | double | The total discount of the expense | | `total_amount` | double | The total amount of the expense | | `contact_id` | string | The contact ID of the expense | | `updated_at` | string | The date and time the expense was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=documents` — includes the related Documents object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this expense in the source accounting platform | | `document_number` | string | The document number of the expense | | `currency_id` | enum | The ISO-4217 currency code of the expense | | `currency_rate` | double | The currency rate of the expense | | `memo` | string | The memo or notes of the expense | | `account_id` | string | The account ID of the expense | | `payment_mode` | string | The payment mode of the expense | | `posted_date` | string | The posted date of the expense | | `sub_total` | double | The sub total of the expense | | `tax_amount` | double | The tax amount of the expense | | `total_discount` | double | The total discount of the expense | | `total_amount` | double | The total amount of the expense | | `contact_id` | string | The contact ID of the expense | | `updated_at` | string | The date and time the expense was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/goods_receipt_notes/overview The Goods Receipt Notes data model. The Goods Receipt Notes data model. ## Attributes ### Goods Receipt Notes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `description` | string | | | `document_number` | string | | | `posted_date` | string | | | `delivery_date` | string | | | `currency_id` | enum | | | `currency_rate` | double | | | `sub_total` | double | | | `tax_amount` | double | | | `total_discount` | double | | | `total_amount` | double | | | `payment_mode` | string | | | `status` | enum | | | `contact_id` | string | | | `purchase_order_ids` | array | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/income_statements/overview An Income Statement is a financial report that shows a business's revenue, expenses, and net income or loss over a specific period of time. In an accounting platform, an income statement is typically generated automatically based on the financial transactions that have been recorded in the system. The Income Statement Data Model represents a financial report that shows a business's revenue, expenses, and net income or loss over a specific period of time. In an accounting platform, an income statement is typically generated automatically based on the financial transactions that have been recorded in the system. * **Unified income statement properties**: Essential income statement details, such as period dates, revenue, expenses, and profit calculations, are standardized across different accounting platforms * **Hierarchical line item structure**: The model supports nested line items for revenue, cost of goods sold, and operating expenses, enabling detailed breakdowns of financial performance * **Automatic generation**: Income statements are typically generated automatically based on recorded financial transactions ## Attributes ### Income Statements Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this income statement | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this income statement in the source accounting platform | | `revenue` | object | The line items for revenue of the income statement report | | `cost_of_goods_sold` | object | The line items for cost of goods sold of the income statement report | | `gross_profit` | double | The gross profit of the income statement report | | `operating_expenses` | object | The line items for operating expenses of the income statement report | | `operating_profit` | double | The operating profit of the income statement report | | `non_operating_revenue` | object | The line items for non-operating revenue of the income statement report | | `non_operating_expenses` | object | The line items for non-operating expenses of the income statement report | | `earnings_before_taxes` | double | | | `taxes` | object | Arbitrary JSON (object or array; shape varies by data model). | | `net_profit` | double | The net profit of the income statement report | | `currency_id` | enum | | | `period_start` | string | The start date of the income statement report period | | `period_end` | string | The end date of the income statement report period | | `updated_at` | string | The date and time the income statement was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/invoice_credit_notes/overview An Invoice Credit Note is a financial transaction representing a reduction that can be applied against one or multiple invoices issued to Customers. The Invoice Credit Notes Data Model represents a financial transaction that can be applied against one or multiple invoices issued to customers. This unified model standardizes and simplifies the management of credit note information across various accounting platforms. * **Unified credit note properties**: Essential credit note details, such as contact ID, document number, total amount, and currency, are standardized across different accounting platforms * **Detailed status tracking**: The model supports various credit note statuses, including draft, submitted, partially paid, paid, overdue, void, and unknown, for better organisation and reporting * **Line item integration**: Credit notes can include an array of associated line items, ensuring comprehensive representation of credit note details and relationships to other data models ## Attributes ### Invoice Credit Notes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this invoice credit note | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this invoice credit note in the source accounting platform | | `contact_id` | string | The contact ID of the invoice credit note | | `document_number` | string | The document number of the invoice credit note | | `total_amount` | double | The total amount of the invoice credit note | | `total_discount` | double | | | `remaining_credit` | double | The remaining credit amount of the invoice credit note | | `shipping_amount` | double | | | `posted_date` | string | The posted date of the invoice credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the invoice credit note | | `status` | enum | The status of the invoice credit note | | `invoice_ids` | array | The invoice IDs associated with the invoice credit note | | `updated_at` | string | The date and time the invoice credit note was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Invoice credit note is in draft status and has not been finalized | | `SUBMITTED` | Invoice credit note has been submitted but not yet paid | | `PARTIALLY_PAID` | Invoice credit note has received partial payment | | `PAID` | Invoice credit note has been fully paid | | `OVERDUE` | Invoice credit note has passed its due date without payment | | `VOID` | Invoice credit note has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this invoice credit note in the source accounting platform | | `contact_id` | string | The contact ID of the invoice credit note | | `document_number` | string | The document number of the invoice credit note | | `total_amount` | double | The total amount of the invoice credit note | | `total_discount` | double | | | `remaining_credit` | double | The remaining credit amount of the invoice credit note | | `shipping_amount` | double | | | `posted_date` | string | The posted date of the invoice credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the invoice credit note | | `status` | enum | The status of the invoice credit note | | `invoice_ids` | array | The invoice IDs associated with the invoice credit note | | `updated_at` | string | The date and time the invoice credit note was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/invoice_payments/overview The payments recorded against Invoices. The Invoice Payments Data Model represents payments recorded against invoices. This unified model streamlines the representation and management of invoice payment information across multiple accounting platforms. * **Unified payment properties**: Essential payment details, such as amount, currency, payment date, and payment mode, are standardized across different accounting platforms * **Linked to contacts, accounts, and invoices**: Each payment entry is connected to a specific contact, account, and invoice using their respective platform IDs, ensuring accurate data representation and easier cross-referencing * **Currency rate conversion support**: The `currency_rate` property enables the tracking of currency conversion rates between the payment currency and the base currency, facilitating accurate financial reporting ## Attributes ### Invoice Payments Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this invoice payment | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this invoice payment in the source accounting platform | | `payment_id` | string | | | `invoice_id` | string | The invoice ID of the invoice payment | | `account_id` | string | The account ID of the invoice payment | | `credit_note_id` | string | The credit note ID associated with the invoice payment (if paying via credit note) | | `amount` | double | The total amount of the invoice payment | | `payment_mode` | string | The payment mode of the invoice payment | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice payment | | `document_number` | string | The document number of the invoice payment | | `memo` | string | The memo or notes of the invoice payment | | `payment_date` | string | The payment date of the invoice payment | | `contact_id` | string | The contact ID of the invoice payment | | `updated_at` | string | The date and time the invoice payment was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=invoice` — includes the related Invoice object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=account` — includes the related Account object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this invoice payment in the source accounting platform | | `payment_id` | string | | | `invoice_id` | string | The invoice ID of the invoice payment | | `account_id` | string | The account ID of the invoice payment | | `credit_note_id` | string | The credit note ID associated with the invoice payment (if paying via credit note) | | `amount` | double | The total amount of the invoice payment | | `payment_mode` | string | The payment mode of the invoice payment | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice payment | | `document_number` | string | The document number of the invoice payment | | `memo` | string | The memo or notes of the invoice payment | | `payment_date` | string | The payment date of the invoice payment | | `contact_id` | string | The contact ID of the invoice payment | | `updated_at` | string | The date and time the invoice payment was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/invoices/overview An itemized record of goods sold or services provided to a customer. **The Invoices Data Model** represents an itemized record of goods sold or services provided to a customer. This unified model simplifies handling invoice-related information across different accounting platforms. * **Unified invoice properties**: Essential invoice details like document number, due date, currency, status, and total amounts are standardized across different accounting platforms * **Linked entities**: Invoices can be associated with contacts, line items, payments, and sales orders, providing a complete view of the invoicing process and related transactions * **Flexible status tracking**: The model supports a range of invoice statuses, such as draft, submitted, partially paid, and overdue, for better organisation and reporting ## Attributes ### Invoices Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this invoice | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this invoice in the source accounting platform | | `contact_id` | string | The contact ID of the invoice | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice | | `document_number` | string | The document number of the invoice | | `posted_date` | string | The posted date of the invoice | | `due_date` | string | The due date of the invoice | | `status` | enum | The status of the invoice | | `sub_total` | double | The sub total of the invoice | | `tax_amount` | double | The tax amount of the invoice | | `total_discount` | double | The total discount of the invoice | | `shipping_amount` | double | | | `total_amount` | double | The total amount of the invoice | | `amount_paid` | double | | | `amount_refunded` | double | | | `amount_credited` | double | | | `amount_due` | double | The amount due of the invoice | | `memo` | string | The memo or notes of the invoice | | `subscription_id` | string | | | `payment_link` | string | | | `payment_link_expires_at` | string | | | `transaction_ids` | array | | | `order_ids` | array | | | `sales_order_ids` | array | The sales order IDs associated with the invoice | | `created_at` | string | | | `updated_at` | string | The date and time the invoice was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Invoice is in draft status and has not been finalized | | `SUBMITTED` | Invoice has been submitted but not yet paid | | `PARTIALLY_PAID` | Invoice has received partial payment | | `PAID` | Invoice has been fully paid | | `OVERDUE` | Invoice has passed its due date without payment | | `VOID` | Invoice has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=addresses` — includes the related Addresses object(s). * `expand=documents` — includes the related Documents object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this invoice in the source accounting platform | | `contact_id` | string | The contact ID of the invoice | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice | | `document_number` | string | The document number of the invoice | | `posted_date` | string | The posted date of the invoice | | `due_date` | string | The due date of the invoice | | `status` | enum | The status of the invoice | | `sub_total` | double | The sub total of the invoice | | `tax_amount` | double | The tax amount of the invoice | | `total_discount` | double | The total discount of the invoice | | `shipping_amount` | double | | | `total_amount` | double | The total amount of the invoice | | `amount_paid` | double | | | `amount_refunded` | double | | | `amount_credited` | double | | | `amount_due` | double | The amount due of the invoice | | `memo` | string | The memo or notes of the invoice | | `subscription_id` | string | | | `payment_link` | string | | | `payment_link_expires_at` | string | | | `transaction_ids` | array | | | `order_ids` | array | | | `sales_order_ids` | array | The sales order IDs associated with the invoice | | `created_at` | string | | | `updated_at` | string | The date and time the invoice was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/items/overview The Items Data Model is designed to simplify the management and retrieval of item-related information across various accounting platforms. **The Items Data Model** represents products or services that can be sold or purchased. This unified model simplifies handling item-related information across various accounting platforms. * **Unified item properties**: Essential item details such as name, description, status, and type are standardized across different accounting platforms * **Item detail flexibility**: The model supports separate details for items being purchased (`bill_item`) and items being sold (`invoice_item`), enabling accurate tracking of item-related transactions * **Associated accounts and tax rates**: Each item can be linked to specific purchase and sales accounts, as well as purchase and sales tax rates, for seamless integration with other accounting data models ## Attributes ### Items Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this item | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this item in the source accounting platform | | `name` | string | The name of the item | | `description` | string | The description of the item | | `code` | string | The reference code of the item | | `sku` | string | | | `price` | double | | | `currency_id` | enum | | | `type` | enum | The type of the item | | `status` | enum | The status of the item | | `quantity_on_hand` | integer | The quantity on hand for the item | | `is_bill_item` | boolean | Whether there are details (bill\_item) of this item getting purchased | | `bill_item` | object | Item details of this item getting purchased | | `is_invoice_item` | boolean | Whether there are details (invoice\_item) of this item getting sold | | `invoice_item` | object | Item details of this item getting sold | | `created_at` | string | | | `updated_at` | string | The date and time the item was last updated | ### Type Enum Values | Value | Description | | - | - | | `INVENTORY` | Item is tracked as inventory | | `NON_INVENTORY` | Item is not tracked as inventory | | `SERVICE` | Item represents a service | | `DIGITAL` | Item is a digital product/download | | `UNKNOWN` | Type cannot be determined from the platform | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Item is in draft status and not yet published | | `ACTIVE` | Item is active and available for use | | `ARCHIVED` | Item has been archived | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=variants` — includes the related Variants object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this item in the source accounting platform | | `name` | string | The name of the item | | `description` | string | The description of the item | | `code` | string | The reference code of the item | | `sku` | string | | | `price` | double | | | `currency_id` | enum | | | `type` | enum | The type of the item | | `status` | enum | The status of the item | | `quantity_on_hand` | integer | The quantity on hand for the item | | `is_bill_item` | boolean | Whether there are details (bill\_item) of this item getting purchased | | `bill_item` | object | Item details of this item getting purchased | | `is_invoice_item` | boolean | Whether there are details (invoice\_item) of this item getting sold | | `invoice_item` | object | Item details of this item getting sold | | `created_at` | string | | | `updated_at` | string | The date and time the item was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/journal_entries/overview A Journal is a running record of a company's financial transactions used to record the debits and credits of each transaction. **The Journal Entries Data Model** represents a running record of a company's financial transactions used to record the debits and credits of each transaction. This unified model simplifies the management and retrieval of journal entry information across various accounting platforms. * **Unified journal entry properties**: Essential journal entry details, such as account ID, amount, currency, description, and posted date, are standardized across different accounting platforms * **Journal entry lines**: The `journal_lines` property includes an array of related journal lines, providing a comprehensive view of the journal entry's constituent transactions ## Attributes ### Journal Entries Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this journal entry | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this journal entry in the source accounting platform | | `account_id` | string | The account ID of the journal entry | | `amount` | double | The total amount of the journal entry | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the journal entry | | `journal_entry_type` | string | The type of the journal entry | | `description` | string | The description of the journal entry | | `posted_date` | string | The posted date of the journal entry | | `document_number` | string | The document number of the journal entry | | `business_unit_id` | string | The business unit ID of the journal entry | | `updated_at` | string | The date and time the journal entry was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=journal_lines` — includes the related Journal Lines object(s). * `expand=documents` — includes the related Documents object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this journal entry in the source accounting platform | | `account_id` | string | The account ID of the journal entry | | `amount` | double | The total amount of the journal entry | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the journal entry | | `journal_entry_type` | string | The type of the journal entry | | `description` | string | The description of the journal entry | | `posted_date` | string | The posted date of the journal entry | | `document_number` | string | The document number of the journal entry | | `business_unit_id` | string | The business unit ID of the journal entry | | `updated_at` | string | The date and time the journal entry was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/line_item/overview Line items across invoices, bills, orders, and other parent records. Line items are individual rows on parent documents (invoices, bills, purchase orders, etc.). Query them directly with `parent_id` and `parent_type` filters. ## Attributes ### Line Item Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `parent_id` | string | | | `parent_type` | enum | | | `item_id` | string | | | `name` | string | | | `description` | string | | | `quantity` | double | | | `unit_amount` | double | | | `tax_amount` | double | | | `discount_amount` | double | | | `sub_total` | double | | | `total_amount` | double | | | `tax_id` | string | | | `account_id` | string | | | `variant_id` | string | | | `tracking_category_ids` | array | | | `created_at` | string | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=item` — includes the related Item object(s). * `expand=tax` — includes the related Tax object(s). * `expand=account` — includes the related Account object(s). * `expand=variant` — includes the related Variant object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/projects/overview The Projects Data Model is designed to simplify the management and retrieval of projects information across various accounting platforms. The Projects Data Model represents projects used to track and organize financial transactions across various accounting platforms. This unified model simplifies the management and retrieval of project information. * **Unified project properties**: Essential project details, such as name, description, and status, are standardized across different accounting platforms * **Project tracking**: Projects enable businesses to track financial transactions and expenses separately, providing better visibility into project-specific financial performance ## Attributes ### Projects Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this project | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this project in the source accounting platform | | `name` | string | The name of the project | | `description` | string | The description of the project | | `status` | string | The status of the project | | `updated_at` | string | The date and time the project was last updated | ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this project in the source accounting platform | | `name` | string | The name of the project | | `description` | string | The description of the project | | `status` | string | The status of the project | | `updated_at` | string | The date and time the project was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/purchase_orders/overview A record of goods or services purchased from a vendor. The Purchase Orders Data Model represents a record of goods or services purchased from a vendor. This unified model simplifies the management and access of purchase order information across various accounting platforms. * **Unified purchase order properties**: Essential details, such as contact information, document number, dates, description, payment mode, and currency, are standardized across different accounting platforms * **Financial calculations**: The model includes properties for tax amount, discounts, subtotals, and total amounts, enabling accurate financial calculations and reporting * **Association with bills**: The bills property links purchase orders to their associated bills, facilitating the tracking and management of related financial transactions ## Attributes ### Purchase Orders Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this purchase order | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this purchase order in the source accounting platform | | `description` | string | The description of the purchase order | | `document_number` | string | The document number of the purchase order | | `posted_date` | string | The posted date of the purchase order | | `delivery_date` | string | The delivery date of the purchase order | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the purchase order | | `sub_total` | double | The sub total of the purchase order | | `tax_amount` | double | The tax amount of the purchase order | | `total_discount` | double | The total discount of the purchase order | | `total_amount` | double | The total amount of the purchase order | | `payment_mode` | string | The payment mode of the purchase order | | `status` | enum | The status of the purchase order | | `contact_id` | string | The contact ID of the purchase order | | `bill_ids` | array | The bill IDs associated with the purchase order | | `updated_at` | string | The date and time the purchase order was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Purchase order is in draft status and has not been finalized | | `SUBMITTED` | Purchase order has been submitted but not yet paid | | `PARTIALLY_PAID` | Purchase order has received partial payment | | `PAID` | Purchase order has been fully paid | | `OVERDUE` | Purchase order has passed its due date without payment | | `VOID` | Purchase order has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this purchase order in the source accounting platform | | `description` | string | The description of the purchase order | | `document_number` | string | The document number of the purchase order | | `posted_date` | string | The posted date of the purchase order | | `delivery_date` | string | The delivery date of the purchase order | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the purchase order | | `sub_total` | double | The sub total of the purchase order | | `tax_amount` | double | The tax amount of the purchase order | | `total_discount` | double | The total discount of the purchase order | | `total_amount` | double | The total amount of the purchase order | | `payment_mode` | string | The payment mode of the purchase order | | `status` | enum | The status of the purchase order | | `contact_id` | string | The contact ID of the purchase order | | `bill_ids` | array | The bill IDs associated with the purchase order | | `updated_at` | string | The date and time the purchase order was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/sales_orders/overview A record of goods or services sold to a customer. The Sales Orders Data Model represents a record of goods or services sold to a customer. This unified model standardizes information related to sales orders across various accounting platforms. * **Unified sales order properties**: Essential sales order information, such as contact ID, document number, dates, description, payment mode, and currency-related data, are standardized across different accounting platforms * **Financial calculations**: The model includes properties for total discount, tax amount, sub-total, and total amount, facilitating accurate financial reporting and analysis * **Invoice associations**: The `invoices` property links sales orders to their corresponding invoices, enabling seamless navigation and cross-referencing between the two data models ## Attributes ### Sales Orders Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this sales order | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this sales order in the source accounting platform | | `posted_date` | string | The posted date of the sales order | | `delivery_date` | string | The delivery date of the sales order | | `description` | string | The description of the sales order | | `document_number` | string | The document number of the sales order | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the sales order | | `sub_total` | double | The sub total of the sales order | | `tax_amount` | double | The tax amount of the sales order | | `total_discount` | double | The total discount of the sales order | | `total_amount` | double | The total amount of the sales order | | `payment_mode` | string | The payment mode of the sales order | | `status` | enum | The status of the sales order | | `contact_id` | string | The contact ID of the sales order | | `invoice_ids` | array | The invoice IDs associated with the sales order | | `updated_at` | string | The date and time the sales order was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Sales order is in draft status and has not been finalized | | `SUBMITTED` | Sales order has been submitted but not yet paid | | `PARTIALLY_PAID` | Sales order has received partial payment | | `PAID` | Sales order has been fully paid | | `OVERDUE` | Sales order has passed its due date without payment | | `VOID` | Sales order has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this sales order in the source accounting platform | | `posted_date` | string | The posted date of the sales order | | `delivery_date` | string | The delivery date of the sales order | | `description` | string | The description of the sales order | | `document_number` | string | The document number of the sales order | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the sales order | | `sub_total` | double | The sub total of the sales order | | `tax_amount` | double | The tax amount of the sales order | | `total_discount` | double | The total discount of the sales order | | `total_amount` | double | The total amount of the sales order | | `payment_mode` | string | The payment mode of the sales order | | `status` | enum | The status of the sales order | | `contact_id` | string | The contact ID of the sales order | | `invoice_ids` | array | The invoice IDs associated with the sales order | | `updated_at` | string | The date and time the sales order was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/subscriptions/overview The Subscription object represents a recurring billing arrangement with a contact, automatically generating invoices at regular intervals. **The Subscription Data Model** represents a recurring billing arrangement with a contact. Subscriptions automatically generate invoices at regular intervals and track all related transactions. * **Automated billing**: Generate invoices automatically based on billing interval * **Complete history**: Track all invoices, payments, and transactions generated by the subscription * **Flexible intervals**: Support for daily, weekly, monthly, and annual billing cycles * **Status management**: Track subscription lifecycle from trial through cancellation ## Attributes ### Subscriptions Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this subscription | | `rootfi_created_at` | string | When this subscription was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this subscription was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific subscription identifier | | `contact_id` | string | Reference to the Contact subscribed | | `currency_id` | enum | ISO 4217 currency code for subscription charges | | `status` | enum | Current status of the subscription | | `amount` | double | Recurring charge amount per billing cycle | | `interval` | enum | Billing frequency unit (day, week, month, year) | | `interval_count` | integer | Number of intervals between billings (e.g., 2 = every 2 months) | | `next_billing_date` | string | Next scheduled billing date (ISO 8601) | | `last_invoice_date` | string | Date when the last invoice was generated (ISO 8601) | | `last_payment_date` | string | Date when the last successful payment was received (ISO 8601) | | `invoice_ids` | array | References to all invoices generated from this subscription | | `transaction_ids` | array | References to all transactions (payments, refunds, fees) | | `line_item_ids` | array | | | `created_at` | string | Original creation timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Subscription is active and billing normally | | `IN_TRIAL` | Subscription is in a trial period (no charges) | | `CANCELED` | Subscription has been canceled and will not renew | | `PAUSED` | Subscription is temporarily paused | | `PAST_DUE` | Subscription has failed payment and is past due | | `INCOMPLETE` | Subscription setup is incomplete | | `UNKNOWN` | Status cannot be determined | ### Interval Enum Values | Value | Description | | - | - | | `DAY` | Daily billing | | `WEEK` | Weekly billing | | `MONTH` | Monthly billing | | `YEAR` | Annual billing | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Platform-specific subscription identifier | | `contact_id` | string | Reference to the Contact subscribed | | `currency_id` | enum | ISO 4217 currency code for subscription charges | | `status` | enum | Current status of the subscription | | `amount` | double | Recurring charge amount per billing cycle | | `interval` | enum | Billing frequency unit (day, week, month, year) | | `interval_count` | integer | Number of intervals between billings (e.g., 2 = every 2 months) | | `next_billing_date` | string | Next scheduled billing date (ISO 8601) | | `last_invoice_date` | string | Date when the last invoice was generated (ISO 8601) | | `last_payment_date` | string | Date when the last successful payment was received (ISO 8601) | | `invoice_ids` | array | References to all invoices generated from this subscription | | `transaction_ids` | array | References to all transactions (payments, refunds, fees) | | `line_item_ids` | array | | | `created_at` | string | Original creation timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/tax-rates/overview A Tax Rate is the percentage at which an individual or corporation is taxed. **The Tax Rates Data Model** represents the percentage at which an individual or corporation is taxed. This unified model provides a unified representation of tax rates across various accounting platforms. * **Unified tax rate properties**: Essential tax rate details, such as name, code, effective tax rate, and total tax rate, are standardized across different accounting platforms * **Tax components support**: The data model encompasses an array of individual tax components, enabling the representation of complex tax structures and relationships between components * **Effective tax rate calculation**: The model accounts for the compounding effects of all tax components, providing an accurate effective tax rate for each entry ## Attributes ### Tax Rates Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this tax rate | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this tax rate in the source accounting platform | | `name` | string | The display name of the tax rate | | `code` | string | The simple ID or code for the tax rate | | `rate` | double | | | `tax_type` | string | The type of tax as mentioned in the accounting platform | | `effective_tax_rate` | double | The total tax rate after accounting for the compounding effects of all tax components | | `total_tax_rate` | double | The sum of all the tax rate components | | `components` | object | The list of tax rate components | | `jurisdiction` | string | | | `status` | enum | | | `created_at` | string | | | `updated_at` | string | The date and time the tax rate was last updated | ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this tax rate in the source accounting platform | | `name` | string | The display name of the tax rate | | `code` | string | The simple ID or code for the tax rate | | `rate` | double | | | `tax_type` | string | The type of tax as mentioned in the accounting platform | | `effective_tax_rate` | double | The total tax rate after accounting for the compounding effects of all tax components | | `total_tax_rate` | double | The sum of all the tax rate components | | `components` | object | The list of tax rate components | | `jurisdiction` | string | | | `status` | enum | | | `created_at` | string | | | `updated_at` | string | The date and time the tax rate was last updated | # Create a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-contact /openapi_v4_core.json post /v4/core/companies/{companyId}/contacts # Create a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-subscription /openapi_v4_core.json post /v4/core/companies/{companyId}/subscriptions # Create a tax rate Source: https://integrations.docs.commenda.io/api-reference/accounting/create-a-tax-rate /openapi_v4_core.json post /v4/core/companies/{companyId}/tax_rates # Create an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-invoice /openapi_v4_core.json post /v4/core/companies/{companyId}/invoices # Create an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-invoice-credit-note /openapi_v4_core.json post /v4/core/companies/{companyId}/invoice_credit_notes # Create an item Source: https://integrations.docs.commenda.io/api-reference/accounting/create-an-item /openapi_v4_core.json post /v4/core/companies/{companyId}/items # Get a company info Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-company-info /openapi_v4_core.json get /v4/core/companies/{companyId}/company_info/{id} # Get a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-contact /openapi_v4_core.json get /v4/core/companies/{companyId}/contacts/{id} # Get a line item Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-line-item /openapi_v4_core.json get /v4/core/companies/{companyId}/line_item/{id} # Get a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-subscription /openapi_v4_core.json get /v4/core/companies/{companyId}/subscriptions/{id} # Get a tax rate Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-tax-rate /openapi_v4_core.json get /v4/core/companies/{companyId}/tax_rates/{id} # Get a tracking category Source: https://integrations.docs.commenda.io/api-reference/accounting/get-a-tracking-category /openapi_v4_core.json get /v4/core/companies/{companyId}/tracking_categories/{id} # Get an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-invoice /openapi_v4_core.json get /v4/core/companies/{companyId}/invoices/{id} # Get an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-invoice-credit-note /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_credit_notes/{id} # Get an item Source: https://integrations.docs.commenda.io/api-reference/accounting/get-an-item /openapi_v4_core.json get /v4/core/companies/{companyId}/items/{id} # List company info Source: https://integrations.docs.commenda.io/api-reference/accounting/list-company-info /openapi_v4_core.json get /v4/core/companies/{companyId}/company_info # List contacts Source: https://integrations.docs.commenda.io/api-reference/accounting/list-contacts /openapi_v4_core.json get /v4/core/companies/{companyId}/contacts # List invoice credit notes Source: https://integrations.docs.commenda.io/api-reference/accounting/list-invoice-credit-notes /openapi_v4_core.json get /v4/core/companies/{companyId}/invoice_credit_notes # List invoices Source: https://integrations.docs.commenda.io/api-reference/accounting/list-invoices /openapi_v4_core.json get /v4/core/companies/{companyId}/invoices # List items Source: https://integrations.docs.commenda.io/api-reference/accounting/list-items /openapi_v4_core.json get /v4/core/companies/{companyId}/items # List line item Source: https://integrations.docs.commenda.io/api-reference/accounting/list-line-item /openapi_v4_core.json get /v4/core/companies/{companyId}/line_item # List subscriptions Source: https://integrations.docs.commenda.io/api-reference/accounting/list-subscriptions /openapi_v4_core.json get /v4/core/companies/{companyId}/subscriptions # List tax rates Source: https://integrations.docs.commenda.io/api-reference/accounting/list-tax-rates /openapi_v4_core.json get /v4/core/companies/{companyId}/tax_rates # List tracking categories Source: https://integrations.docs.commenda.io/api-reference/accounting/list-tracking-categories /openapi_v4_core.json get /v4/core/companies/{companyId}/tracking_categories # Update a contact Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-contact /openapi_v4_core.json put /v4/core/companies/{companyId}/contacts # Update a subscription Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-subscription /openapi_v4_core.json put /v4/core/companies/{companyId}/subscriptions # Update a tax rate Source: https://integrations.docs.commenda.io/api-reference/accounting/update-a-tax-rate /openapi_v4_core.json put /v4/core/companies/{companyId}/tax_rates # Update an invoice Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-invoice /openapi_v4_core.json put /v4/core/companies/{companyId}/invoices # Update an invoice credit note Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-invoice-credit-note /openapi_v4_core.json put /v4/core/companies/{companyId}/invoice_credit_notes # Update an item Source: https://integrations.docs.commenda.io/api-reference/accounting/update-an-item /openapi_v4_core.json put /v4/core/companies/{companyId}/items # Get a company Source: https://integrations.docs.commenda.io/api-reference/crm/get-a-company /openapi_v4_core.json get /v4/core/companies/{companyId}/companies/{id} # Get a lead Source: https://integrations.docs.commenda.io/api-reference/crm/get-a-lead /openapi_v4_core.json get /v4/core/companies/{companyId}/leads/{id} # Get a note Source: https://integrations.docs.commenda.io/api-reference/crm/get-a-note /openapi_v4_core.json get /v4/core/companies/{companyId}/notes/{id} # Get an opportunity Source: https://integrations.docs.commenda.io/api-reference/crm/get-an-opportunity /openapi_v4_core.json get /v4/core/companies/{companyId}/opportunities/{id} # Get an owner Source: https://integrations.docs.commenda.io/api-reference/crm/get-an-owner /openapi_v4_core.json get /v4/core/companies/{companyId}/owners/{id} # List companies Source: https://integrations.docs.commenda.io/api-reference/crm/list-companies /openapi_v4_core.json get /v4/core/companies/{companyId}/companies # List leads Source: https://integrations.docs.commenda.io/api-reference/crm/list-leads /openapi_v4_core.json get /v4/core/companies/{companyId}/leads # List notes Source: https://integrations.docs.commenda.io/api-reference/crm/list-notes /openapi_v4_core.json get /v4/core/companies/{companyId}/notes # List opportunities Source: https://integrations.docs.commenda.io/api-reference/crm/list-opportunities /openapi_v4_core.json get /v4/core/companies/{companyId}/opportunities # List owners Source: https://integrations.docs.commenda.io/api-reference/crm/list-owners /openapi_v4_core.json get /v4/core/companies/{companyId}/owners # Get an inventory Source: https://integrations.docs.commenda.io/api-reference/e-commerce/get-an-inventory /openapi_v4_core.json get /v4/core/companies/{companyId}/inventory/{id} # List inventory Source: https://integrations.docs.commenda.io/api-reference/e-commerce/list-inventory /openapi_v4_core.json get /v4/core/companies/{companyId}/inventory # Get a balance Source: https://integrations.docs.commenda.io/api-reference/payments/get-a-balance /openapi_v4_core.json get /v4/core/companies/{companyId}/balances/{id} # Get a dispute Source: https://integrations.docs.commenda.io/api-reference/payments/get-a-dispute /openapi_v4_core.json get /v4/core/companies/{companyId}/disputes/{id} # Get a payout Source: https://integrations.docs.commenda.io/api-reference/payments/get-a-payout /openapi_v4_core.json get /v4/core/companies/{companyId}/payouts/{id} # Get a transaction Source: https://integrations.docs.commenda.io/api-reference/payments/get-a-transaction /openapi_v4_core.json get /v4/core/companies/{companyId}/transactions/{id} # Get an order Source: https://integrations.docs.commenda.io/api-reference/payments/get-an-order /openapi_v4_core.json get /v4/core/companies/{companyId}/orders/{id} # List balances Source: https://integrations.docs.commenda.io/api-reference/payments/list-balances /openapi_v4_core.json get /v4/core/companies/{companyId}/balances # List disputes Source: https://integrations.docs.commenda.io/api-reference/payments/list-disputes /openapi_v4_core.json get /v4/core/companies/{companyId}/disputes # List orders Source: https://integrations.docs.commenda.io/api-reference/payments/list-orders /openapi_v4_core.json get /v4/core/companies/{companyId}/orders # List payouts Source: https://integrations.docs.commenda.io/api-reference/payments/list-payouts /openapi_v4_core.json get /v4/core/companies/{companyId}/payouts # List transactions Source: https://integrations.docs.commenda.io/api-reference/payments/list-transactions /openapi_v4_core.json get /v4/core/companies/{companyId}/transactions # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/balances/overview The Balance object represents the current account balance for a payment gateway account. The Balance Data Model represents the current account balance for a payment gateway account. This is typically a computed view showing available funds across different categories. * **Real-time balance**: Current snapshot of available funds * **Currency-specific**: Balances are tracked per currency * **Balance categories**: Track available, pending, and total balances separately ## Attributes ### Balances Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this balance record | | `rootfi_created_at` | string | When this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this record was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific balance identifier | | `total_balance` | double | Total balance including pending funds | | `available_balance` | double | Funds available for immediate use or payout | | `pending_balance` | double | Funds not yet available (processing, holds, etc.) | | `currency_id` | enum | ISO 4217 currency code | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/companies/overview A company is a business tracked in a CRM — the account that contacts belong to. The Companies Data Model represents a business or organisation in a CRM, often called an "account". This unified model standardizes company records across different CRM platforms. * **Firmographic properties**: Core details like name, industry, website, number of employees, and annual revenue are standardized across CRM platforms * **Relationships**: Each company is associated with the contacts who work there and the owner responsible for the account * **Activity tracking**: The last activity timestamp reflects the most recent interaction with the company ## Attributes ### Companies Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this company | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this company in the source CRM platform | | `name` | string | The name of the company | | `description` | string | A description of the company | | `industry` | string | The industry the company operates in | | `website` | string | The company's website URL | | `domain` | string | The company's domain | | `number_of_employees` | integer | The number of employees at the company | | `annual_revenue` | double | The company's annual revenue | | `currency_id` | enum | The ISO-4217 currency code for the company's annual revenue | | `owner_id` | string | The ID of the user who owns this company | | `created_at` | string | | | `updated_at` | string | The date and time the company was last updated | | `last_activity_at` | string | The date and time of the most recent activity with the company | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/company-info/overview The Company Info Data Model is designed to simplify the management and retrieval of company-related information across various accounting platforms. **The Company Info Data Model** represents company-related information from various accounting platforms. This unified model simplifies the management and retrieval of company details. * **Unified company properties**: Essential company details, such as name, legal name, base currency, and registration number, are standardized across different accounting platforms * **Comprehensive contact information**: Retrieve company addresses, external links, and phone numbers for a complete view of company contacts * **Financial year tracking**: Monitor the company's financial year start date for accurate reporting and analysis ## Attributes ### Company Info Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this company info | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this company info in the source accounting platform | | `name` | string | The name of the company | | `legal_name` | string | The legal name of the company | | `tax_number` | string | The tax number of the company | | `registration_number` | string | The registration number of the company | | `base_currency` | string | The base currency of the company | | `fiscal_start_at` | string | The fiscal year start date of the company | | `org_created_at` | string | The date and time the organization was created | | `timezone` | string | | | `updated_at` | string | The date and time the company info was last updated | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=addresses` — includes the related Addresses object(s). * `expand=phone_numbers` — includes the related Phone Numbers object(s). * `expand=external_links` — includes the related External Links object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/contacts/overview A contact is an individual or company that buys or sells goods or services from a business. Commonly referred to as a customer on a corresponding invoice or a vendor for a bill. The Contacts Data Model represents an individual or company that buys or sells goods or services from a business. This unified model simplifies handling contact-related information across various accounting platforms. * **Unified contact properties**: Essential contact details like name, contact person, currency, and tax number are standardized across different accounting platforms * **Comprehensive contact information**: Contacts can include associated data like contact persons, phone numbers, addresses, and external links for a more detailed representation of each contact * **Status tracking**: The model supports tracking the status of each contact, with values like `ACTIVE`, `INACTIVE`, `SUSPENDED`, `ARCHIVED`, and `UNKNOWN`, facilitating better organisation and reporting ## Attributes ### Contacts Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this contact | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this contact in the source accounting platform | | `name` | string | The name of the contact | | `contact_name` | string | The name of the contact person for the contact | | `email` | string | | | `phone` | string | | | `tax_number` | string | The contact's tax number | | `type` | enum | The type of contact | | `status` | enum | The status of the contact | | `currency_id` | enum | The ISO-4217 currency code of the contact | | `registration_number` | string | The contact's identifying or registration number | | `website` | string | | | `created_at` | string | | | `updated_at` | string | The date and time the contact was last updated | ### Type Enum Values | Value | Description | | - | - | | `CUSTOMER` | Contact is a customer who receives invoices | | `VENDOR` | Contact is a vendor who provides bills | | `BOTH` | Contact acts as both customer and vendor | | `UNKNOWN` | Type cannot be determined from the platform | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Contact is active and in good standing | | `INACTIVE` | Contact has been voluntarily deactivated | | `SUSPENDED` | Contact is suspended due to payment/fraud issues | | `ARCHIVED` | Contact has been archived for record-keeping | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=addresses` — includes the related Addresses object(s). * `expand=phone_numbers` — includes the related Phone Numbers object(s). * `expand=external_links` — includes the related External Links object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this contact in the source accounting platform | | `name` | string | The name of the contact | | `contact_name` | string | The name of the contact person for the contact | | `email` | string | | | `phone` | string | | | `tax_number` | string | The contact's tax number | | `type` | enum | The type of contact | | `status` | enum | The status of the contact | | `currency_id` | enum | The ISO-4217 currency code of the contact | | `registration_number` | string | The contact's identifying or registration number | | `website` | string | | | `created_at` | string | | | `updated_at` | string | The date and time the contact was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/disputes/overview The Dispute object represents a contact dispute or chargeback on a payment transaction. The Dispute Data Model represents a contact dispute or chargeback on a payment transaction. Disputes occur when contacts contest charges with their bank or card issuer. * **Chargeback management**: Track disputes from filing through resolution * **Evidence tracking**: Monitor evidence submission deadlines * **Reason categorization**: Standardized dispute reason codes * **Transaction linking**: Connect disputes to original payment transactions ## Attributes ### Disputes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this dispute | | `rootfi_created_at` | string | When this dispute was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this dispute was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific dispute identifier | | `transaction_id` | string | Reference to the disputed Transaction | | `invoice_id` | string | Reference to the related Invoice | | `contact_id` | string | Reference to the Contact | | `currency_id` | enum | ISO 4217 currency code | | `amount` | double | Disputed amount | | `status` | enum | Current dispute status | | `reason` | enum | Standardized dispute reason | | `reason_code` | string | Platform-specific reason code | | `gateway` | string | Payment gateway name | | `gateway_dispute_id` | string | Platform-specific dispute ID | | `evidence_due_date` | string | Deadline for submitting evidence (ISO 8601) | | `resolution_date` | string | Date dispute was resolved (null if pending) (ISO 8601) | | `created_at` | string | Original dispute creation timestamp (ISO 8601) | | `updated_at` | string | Last update timestamp (ISO 8601) | ### Status Enum Values | Value | Description | | - | - | | `OPEN` | Dispute has been filed and is open | | `UNDER_REVIEW` | Platform is reviewing evidence | | `WON` | Merchant won the dispute | | `LOST` | Contact won the dispute | | `WARNING_CLOSED` | Closed with a warning | | `UNKNOWN` | Status cannot be determined | ### Reason Enum Values | Value | Description | | - | - | | `FRAUDULENT` | Transaction was fraudulent | | `DUPLICATE` | Duplicate charge | | `UNRECOGNIZED` | Contact doesn't recognize transaction | | `QUALITY_ISSUE` | Product/service quality issue | | `NOT_RECEIVED` | Product not received | | `CANCELED` | Service was canceled | | `OTHER` | Other reason | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/inventory/overview Inventory tracks stock levels and availability for catalog items across e-commerce platforms. The Inventory Data Model tracks stock quantities, reserved amounts, and availability status for items in your e-commerce catalog. ## Attributes ### Inventory Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this inventory record | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific inventory identifier | | `item_id` | string | Reference to the related item | | `variant_id` | string | | | `description` | string | | | `sku` | string | | | `quantity` | integer | Total quantity on hand | | `reserved_quantity` | integer | Quantity allocated to pending orders | | `available_quantity` | integer | Quantity available for new orders | | `status` | enum | `IN_STOCK`, `LOW_STOCK`, `OUT_OF_STOCK`, `DISCONTINUED` | | `is_trackable` | boolean | | | `reorder_level` | integer | | | `reorder_quantity` | integer | | | `created_at` | string | | | `updated_at` | string | Last update timestamp (ISO 8601) | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/invoice_credit_notes/overview An Invoice Credit Note is a financial transaction representing a reduction that can be applied against one or multiple invoices issued to Customers. The Invoice Credit Notes Data Model represents a financial transaction that can be applied against one or multiple invoices issued to customers. This unified model standardizes and simplifies the management of credit note information across various accounting platforms. * **Unified credit note properties**: Essential credit note details, such as contact ID, document number, total amount, and currency, are standardized across different accounting platforms * **Detailed status tracking**: The model supports various credit note statuses, including draft, submitted, partially paid, paid, overdue, void, and unknown, for better organisation and reporting * **Line item integration**: Credit notes can include an array of associated line items, ensuring comprehensive representation of credit note details and relationships to other data models ## Attributes ### Invoice Credit Notes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this invoice credit note | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this invoice credit note in the source accounting platform | | `contact_id` | string | The contact ID of the invoice credit note | | `document_number` | string | The document number of the invoice credit note | | `total_amount` | double | The total amount of the invoice credit note | | `total_discount` | double | | | `remaining_credit` | double | The remaining credit amount of the invoice credit note | | `shipping_amount` | double | | | `posted_date` | string | The posted date of the invoice credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the invoice credit note | | `status` | enum | The status of the invoice credit note | | `invoice_ids` | array | The invoice IDs associated with the invoice credit note | | `updated_at` | string | The date and time the invoice credit note was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Invoice credit note is in draft status and has not been finalized | | `SUBMITTED` | Invoice credit note has been submitted but not yet paid | | `PARTIALLY_PAID` | Invoice credit note has received partial payment | | `PAID` | Invoice credit note has been fully paid | | `OVERDUE` | Invoice credit note has passed its due date without payment | | `VOID` | Invoice credit note has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=contact` — includes the related Contact object(s). * `expand=currency` — includes the related Currency object(s). * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this invoice credit note in the source accounting platform | | `contact_id` | string | The contact ID of the invoice credit note | | `document_number` | string | The document number of the invoice credit note | | `total_amount` | double | The total amount of the invoice credit note | | `total_discount` | double | | | `remaining_credit` | double | The remaining credit amount of the invoice credit note | | `shipping_amount` | double | | | `posted_date` | string | The posted date of the invoice credit note | | `currency_id` | enum | ISO 4217 currency code | | `memo` | string | The memo or notes of the invoice credit note | | `status` | enum | The status of the invoice credit note | | `invoice_ids` | array | The invoice IDs associated with the invoice credit note | | `updated_at` | string | The date and time the invoice credit note was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/invoices/overview An itemized record of goods sold or services provided to a customer. **The Invoices Data Model** represents an itemized record of goods sold or services provided to a customer. This unified model simplifies handling invoice-related information across different accounting platforms. * **Unified invoice properties**: Essential invoice details like document number, due date, currency, status, and total amounts are standardized across different accounting platforms * **Linked entities**: Invoices can be associated with contacts, line items, payments, and sales orders, providing a complete view of the invoicing process and related transactions * **Flexible status tracking**: The model supports a range of invoice statuses, such as draft, submitted, partially paid, and overdue, for better organisation and reporting ## Attributes ### Invoices Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this invoice | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this invoice in the source accounting platform | | `contact_id` | string | The contact ID of the invoice | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice | | `document_number` | string | The document number of the invoice | | `posted_date` | string | The posted date of the invoice | | `due_date` | string | The due date of the invoice | | `status` | enum | The status of the invoice | | `sub_total` | double | The sub total of the invoice | | `tax_amount` | double | The tax amount of the invoice | | `total_discount` | double | The total discount of the invoice | | `shipping_amount` | double | | | `total_amount` | double | The total amount of the invoice | | `amount_paid` | double | | | `amount_refunded` | double | | | `amount_credited` | double | | | `amount_due` | double | The amount due of the invoice | | `memo` | string | The memo or notes of the invoice | | `subscription_id` | string | | | `payment_link` | string | | | `payment_link_expires_at` | string | | | `transaction_ids` | array | | | `order_ids` | array | | | `sales_order_ids` | array | The sales order IDs associated with the invoice | | `created_at` | string | | | `updated_at` | string | The date and time the invoice was last updated | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Invoice is in draft status and has not been finalized | | `SUBMITTED` | Invoice has been submitted but not yet paid | | `PARTIALLY_PAID` | Invoice has received partial payment | | `PAID` | Invoice has been fully paid | | `OVERDUE` | Invoice has passed its due date without payment | | `VOID` | Invoice has been voided or canceled | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=addresses` — includes the related Addresses object(s). * `expand=documents` — includes the related Documents object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this invoice in the source accounting platform | | `contact_id` | string | The contact ID of the invoice | | `currency_id` | enum | ISO 4217 currency code | | `currency_rate` | double | The currency rate of the invoice | | `document_number` | string | The document number of the invoice | | `posted_date` | string | The posted date of the invoice | | `due_date` | string | The due date of the invoice | | `status` | enum | The status of the invoice | | `sub_total` | double | The sub total of the invoice | | `tax_amount` | double | The tax amount of the invoice | | `total_discount` | double | The total discount of the invoice | | `shipping_amount` | double | | | `total_amount` | double | The total amount of the invoice | | `amount_paid` | double | | | `amount_refunded` | double | | | `amount_credited` | double | | | `amount_due` | double | The amount due of the invoice | | `memo` | string | The memo or notes of the invoice | | `subscription_id` | string | | | `payment_link` | string | | | `payment_link_expires_at` | string | | | `transaction_ids` | array | | | `order_ids` | array | | | `sales_order_ids` | array | The sales order IDs associated with the invoice | | `created_at` | string | | | `updated_at` | string | The date and time the invoice was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/items/overview The Items Data Model is designed to simplify the management and retrieval of item-related information across various accounting platforms. **The Items Data Model** represents products or services that can be sold or purchased. This unified model simplifies handling item-related information across various accounting platforms. * **Unified item properties**: Essential item details such as name, description, status, and type are standardized across different accounting platforms * **Item detail flexibility**: The model supports separate details for items being purchased (`bill_item`) and items being sold (`invoice_item`), enabling accurate tracking of item-related transactions * **Associated accounts and tax rates**: Each item can be linked to specific purchase and sales accounts, as well as purchase and sales tax rates, for seamless integration with other accounting data models ## Attributes ### Items Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this item | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this item in the source accounting platform | | `name` | string | The name of the item | | `description` | string | The description of the item | | `code` | string | The reference code of the item | | `sku` | string | | | `price` | double | | | `currency_id` | enum | | | `type` | enum | The type of the item | | `status` | enum | The status of the item | | `quantity_on_hand` | integer | The quantity on hand for the item | | `is_bill_item` | boolean | Whether there are details (bill\_item) of this item getting purchased | | `bill_item` | object | Item details of this item getting purchased | | `is_invoice_item` | boolean | Whether there are details (invoice\_item) of this item getting sold | | `invoice_item` | object | Item details of this item getting sold | | `created_at` | string | | | `updated_at` | string | The date and time the item was last updated | ### Type Enum Values | Value | Description | | - | - | | `INVENTORY` | Item is tracked as inventory | | `NON_INVENTORY` | Item is not tracked as inventory | | `SERVICE` | Item represents a service | | `DIGITAL` | Item is a digital product/download | | `UNKNOWN` | Type cannot be determined from the platform | ### Status Enum Values | Value | Description | | - | - | | `DRAFT` | Item is in draft status and not yet published | | `ACTIVE` | Item is active and available for use | | `ARCHIVED` | Item has been archived | | `UNKNOWN` | Status cannot be determined from the platform | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=variants` — includes the related Variants object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this item in the source accounting platform | | `name` | string | The name of the item | | `description` | string | The description of the item | | `code` | string | The reference code of the item | | `sku` | string | | | `price` | double | | | `currency_id` | enum | | | `type` | enum | The type of the item | | `status` | enum | The status of the item | | `quantity_on_hand` | integer | The quantity on hand for the item | | `is_bill_item` | boolean | Whether there are details (bill\_item) of this item getting purchased | | `bill_item` | object | Item details of this item getting purchased | | `is_invoice_item` | boolean | Whether there are details (invoice\_item) of this item getting sold | | `invoice_item` | object | Item details of this item getting sold | | `created_at` | string | | | `updated_at` | string | The date and time the item was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/leads/overview The Leads data model. The Leads data model. ## Attributes ### Leads Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `name` | string | | | `first_name` | string | | | `last_name` | string | | | `email` | string | | | `company_name` | string | | | `title` | string | | | `lead_source` | string | | | `status` | enum | | | `is_converted` | boolean | | | `converted_contact_id` | string | | | `converted_account_id` | string | | | `converted_opportunity_id` | string | | | `converted_date` | string | | | `owner_id` | string | | | `amount` | double | | | `currency_id` | enum | | | `created_at` | string | | | `updated_at` | string | | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/line_item/overview Line items across invoices, bills, orders, and other parent records. Line items are individual rows on parent documents (invoices, bills, purchase orders, etc.). Query them directly with `parent_id` and `parent_type` filters. ## Attributes ### Line Item Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `parent_id` | string | | | `parent_type` | enum | | | `item_id` | string | | | `name` | string | | | `description` | string | | | `quantity` | double | | | `unit_amount` | double | | | `tax_amount` | double | | | `discount_amount` | double | | | `sub_total` | double | | | `total_amount` | double | | | `tax_id` | string | | | `account_id` | string | | | `variant_id` | string | | | `tracking_category_ids` | array | | | `created_at` | string | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=item` — includes the related Item object(s). * `expand=tax` — includes the related Tax object(s). * `expand=account` — includes the related Account object(s). * `expand=variant` — includes the related Variant object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/notes/overview The Notes data model. The Notes data model. ## Attributes ### Notes Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `content` | string | | | `owner_id` | string | | | `account_id` | string | | | `contact_id` | string | | | `opportunity_id` | string | | | `lead_id` | string | | | `created_at` | string | | | `updated_at` | string | | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/opportunities/overview The Opportunities data model. The Opportunities data model. ## Attributes ### Opportunities Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `name` | string | | | `account_id` | string | | | `contact_id` | string | | | `pipeline_id` | string | | | `pipeline_stage_id` | string | | | `owner_id` | string | | | `amount` | double | | | `currency_id` | enum | | | `status` | enum | | | `probability` | double | | | `close_date` | string | | | `created_at` | string | | | `updated_at` | string | | | `last_activity_at` | string | | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/orders/overview The Order object represents a purchase order, typically linked to an invoice, tracking commercial transaction details with embedded transactions. **The Order Data Model** represents a purchase order, typically linked to an invoice. Orders track the commercial transaction details and can generate invoices. In V4, orders embed complete transaction history for comprehensive financial tracking. * **Invoice generation**: Orders can generate one or more invoices * **Embedded transactions**: Complete payment history embedded in the order object * **Status tracking**: Track both order fulfillment status and payment status * **Line item details**: Detailed breakdown of items in the order ## Attributes ### Orders Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this order | | `rootfi_created_at` | string | When this order was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this order was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific order identifier | | `order_number` | string | | | `contact_id` | string | Reference to the Contact | | `currency_id` | enum | ISO 4217 currency code | | `status` | enum | Current order status | | `payment_status` | enum | Payment state of the order | | `fulfillment_status` | enum | | | `total_amount` | double | Total order amount | | `total_discount` | double | Total discount amount | | `total_tax` | double | Total tax amount | | `shipping_amount` | double | | | `invoice_id` | string | Reference to the primary Invoice | | `invoice_ids` | array | References to all related invoices | | `transaction_ids` | array | | | `created_at` | string | Original creation timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | ### Status Enum Values | Value | Description | | - | - | | `PENDING` | Order created but not yet processed | | `PROCESSING` | Order is being processed | | `COMPLETED` | Order has been fulfilled | | `CANCELED` | Order was canceled | | `ON_HOLD` | Order is temporarily on hold | | `UNKNOWN` | Status cannot be determined | ### Payment Status Enum Values | Value | Description | | - | - | | `DRAFT` | Payment created but not yet initiated | | `PENDING` | Payment initiated but not confirmed | | `PAID` | Payment completed successfully | | `PARTIALLY_PAID` | Partial payment received | | `FAILED` | Payment failed to process | | `REFUNDED` | Payment refunded | | `PARTIALLY_REFUNDED` | Partial refund issued | | `VOIDED` | Payment voided before capture | | `UNKNOWN` | Payment status cannot be determined | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). * `expand=transactions` — includes the related Transactions object(s). * `expand=addresses` — includes the related Addresses object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/owners/overview The Owners data model. The Owner data model. ## Attributes ### Owners Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `name` | string | | | `first_name` | string | | | `last_name` | string | | | `email` | string | | | `is_active` | boolean | | | `created_at` | string | | | `updated_at` | string | | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/payouts/overview The Payout object represents a transfer of funds from the payment platform to the merchant's bank account. **The Payout Data Model** represents a transfer of funds from the payment platform to the merchant's bank account. Payouts aggregate multiple transactions into a single transfer. * **Fund transfers**: Track money moving from payment platform to bank account * **Transaction aggregation**: Link payouts to the transactions they include * **Arrival tracking**: Monitor expected and actual fund arrival dates * **Multiple payout types**: Support for bank account, card, and other payout methods ## Attributes ### Payouts Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this payout | | `rootfi_created_at` | string | When this payout was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this payout was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific payout identifier | | `gateway_account_id` | string | Payment gateway account identifier | | `amount` | double | Payout amount | | `currency_id` | enum | ISO 4217 currency code | | `status` | enum | Current payout status | | `schedule` | enum | Payout schedule type | | `type` | enum | Destination account type | | `method` | string | Payout method details | | `arrival_date` | string | Date funds will arrive in merchant account (ISO 8601) | | `gateway` | string | Payment gateway name | | `destination` | object | Bank account details | | `transaction_ids` | array | Transactions included in this payout | | `created_at` | string | Original creation timestamp (ISO 8601) | | `updated_at` | string | Last update timestamp (ISO 8601) | ### Status Enum Values | Value | Description | | - | - | | `PENDING` | Payout is scheduled but not yet sent | | `IN_TRANSIT` | Payout has been initiated | | `PAID` | Funds have been delivered | | `CANCELED` | Payout was canceled | | `FAILED` | Payout failed to process | | `UNKNOWN` | Status cannot be determined | ### Schedule Enum Values | Value | Description | | - | - | | `MANUAL` | Manually initiated payout | | `AUTOMATIC` | Automatically scheduled payout | | `UNKNOWN` | Schedule type unknown | ### Type Enum Values | Value | Description | | - | - | | `BANK_ACCOUNT` | Payout to bank account | | `CARD` | Payout to debit card | | `FPX` | FPX payment method | | `UNKNOWN` | Destination type unknown | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/pipelines/overview The Pipelines data model. The Pipelines data model. ## Attributes ### Pipelines Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `name` | string | | | `status` | string | | | `created_at` | string | | | `updated_at` | string | | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=stages` — includes the related Stages object(s). # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/subscriptions/overview The Subscription object represents a recurring billing arrangement with a contact, automatically generating invoices at regular intervals. **The Subscription Data Model** represents a recurring billing arrangement with a contact. Subscriptions automatically generate invoices at regular intervals and track all related transactions. * **Automated billing**: Generate invoices automatically based on billing interval * **Complete history**: Track all invoices, payments, and transactions generated by the subscription * **Flexible intervals**: Support for daily, weekly, monthly, and annual billing cycles * **Status management**: Track subscription lifecycle from trial through cancellation ## Attributes ### Subscriptions Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this subscription | | `rootfi_created_at` | string | When this subscription was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this subscription was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific subscription identifier | | `contact_id` | string | Reference to the Contact subscribed | | `currency_id` | enum | ISO 4217 currency code for subscription charges | | `status` | enum | Current status of the subscription | | `amount` | double | Recurring charge amount per billing cycle | | `interval` | enum | Billing frequency unit (day, week, month, year) | | `interval_count` | integer | Number of intervals between billings (e.g., 2 = every 2 months) | | `next_billing_date` | string | Next scheduled billing date (ISO 8601) | | `last_invoice_date` | string | Date when the last invoice was generated (ISO 8601) | | `last_payment_date` | string | Date when the last successful payment was received (ISO 8601) | | `invoice_ids` | array | References to all invoices generated from this subscription | | `transaction_ids` | array | References to all transactions (payments, refunds, fees) | | `line_item_ids` | array | | | `created_at` | string | Original creation timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | ### Status Enum Values | Value | Description | | - | - | | `ACTIVE` | Subscription is active and billing normally | | `IN_TRIAL` | Subscription is in a trial period (no charges) | | `CANCELED` | Subscription has been canceled and will not renew | | `PAUSED` | Subscription is temporarily paused | | `PAST_DUE` | Subscription has failed payment and is past due | | `INCOMPLETE` | Subscription setup is incomplete | | `UNKNOWN` | Status cannot be determined | ### Interval Enum Values | Value | Description | | - | - | | `DAY` | Daily billing | | `WEEK` | Weekly billing | | `MONTH` | Monthly billing | | `YEAR` | Annual billing | ## Expandable Attributes Use the `expand` query parameter to include related objects: * `expand=line_items` — includes the related Line Items object(s). ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Platform-specific subscription identifier | | `contact_id` | string | Reference to the Contact subscribed | | `currency_id` | enum | ISO 4217 currency code for subscription charges | | `status` | enum | Current status of the subscription | | `amount` | double | Recurring charge amount per billing cycle | | `interval` | enum | Billing frequency unit (day, week, month, year) | | `interval_count` | integer | Number of intervals between billings (e.g., 2 = every 2 months) | | `next_billing_date` | string | Next scheduled billing date (ISO 8601) | | `last_invoice_date` | string | Date when the last invoice was generated (ISO 8601) | | `last_payment_date` | string | Date when the last successful payment was received (ISO 8601) | | `invoice_ids` | array | References to all invoices generated from this subscription | | `transaction_ids` | array | References to all transactions (payments, refunds, fees) | | `line_item_ids` | array | | | `created_at` | string | Original creation timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/tax-rates/overview A Tax Rate is the percentage at which an individual or corporation is taxed. **The Tax Rates Data Model** represents the percentage at which an individual or corporation is taxed. This unified model provides a unified representation of tax rates across various accounting platforms. * **Unified tax rate properties**: Essential tax rate details, such as name, code, effective tax rate, and total tax rate, are standardized across different accounting platforms * **Tax components support**: The data model encompasses an array of individual tax components, enabling the representation of complex tax structures and relationships between components * **Effective tax rate calculation**: The model accounts for the compounding effects of all tax components, providing an accurate effective tax rate for each entry ## Attributes ### Tax Rates Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this tax rate | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this tax rate in the source accounting platform | | `name` | string | The display name of the tax rate | | `code` | string | The simple ID or code for the tax rate | | `rate` | double | | | `tax_type` | string | The type of tax as mentioned in the accounting platform | | `effective_tax_rate` | double | The total tax rate after accounting for the compounding effects of all tax components | | `total_tax_rate` | double | The sum of all the tax rate components | | `components` | object | The list of tax rate components | | `jurisdiction` | string | | | `status` | enum | | | `created_at` | string | | | `updated_at` | string | The date and time the tax rate was last updated | ## Properties Supported Fields accepted when creating or updating a record: | Property | Type | Description | | - | - | - | | `platform_id` | string | Unique identifier for this tax rate in the source accounting platform | | `name` | string | The display name of the tax rate | | `code` | string | The simple ID or code for the tax rate | | `rate` | double | | | `tax_type` | string | The type of tax as mentioned in the accounting platform | | `effective_tax_rate` | double | The total tax rate after accounting for the compounding effects of all tax components | | `total_tax_rate` | double | The sum of all the tax rate components | | `components` | object | The list of tax rate components | | `jurisdiction` | string | | | `status` | enum | | | `created_at` | string | | | `updated_at` | string | The date and time the tax rate was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/tracking-categories/overview Tracking Categories are used to classify and track financial data across different segments or dimensions within the business entity. The Tracking Categories Data Model represents categories used to classify and track financial data across different segments or dimensions within the business entity. This unified model simplifies the management and retrieval of tracking category information. * **Unified tracking category properties**: Essential tracking category details, such as name, status, and parent relationships, are standardized across different accounting platforms * **Hierarchical structure**: Tracking categories can be linked to parent categories using the `parent_id`, enabling the representation of complex category structures and relationships * **Financial tracking**: Tracking categories allow businesses to track financial transactions or expenses separately, helping businesses gain greater visibility into their financial performance and make better-informed decisions ## Attributes ### Tracking Categories Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier assigned by Commenda for this tracking category | | `rootfi_created_at` | string | Timestamp when this record was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | Timestamp when this record was last updated in Commenda's system (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Unique identifier for this tracking category in the source accounting platform | | `name` | string | The name of the tracking category | | `status` | enum | The status of the tracking category | | `parent_id` | string | The parent tracking category ID of the tracking category | | `has_children` | boolean | Whether the tracking category has child tracking categories | | `updated_at` | string | The date and time the tracking category was last updated | # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/transactions/overview The Transaction object represents all monetary movements in the payment system - a unified model consolidating payments, refunds, and credit notes. The Transaction Data Model represents all monetary movements in the payment system. This unified model consolidates what were previously separate Payment, Refund, and Credit Note models. Transactions are distinguished by their `type` field. * **Unified financial movements**: All payments, refunds, credit notes, fees, chargebacks, and payouts in a single model * **Type-based filtering**: Query by transaction type to get specific financial movements * **Complete audit trail**: Full relationship tracking to invoices, orders, subscriptions, and original transactions * **Gateway integration**: Detailed payment gateway information and transaction IDs ## Attributes ### Transactions Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | Unique identifier for this transaction | | `rootfi_created_at` | string | When this transaction was created in Commenda's system (ISO 8601) | | `rootfi_updated_at` | string | When this transaction was last updated (ISO 8601) | | `rootfi_integration_type` | enum | | | `platform_id` | string | Platform-specific transaction identifier | | `type` | enum | Type of transaction (`PAYMENT`, `REFUND`, `CREDIT_NOTE`, etc.) | | `invoice_id` | string | Reference to the associated Invoice | | `order_id` | string | Reference to the associated Order (if applicable) | | `subscription_id` | string | Reference to the associated Subscription (for recurring payments) | | `contact_id` | string | Reference to the Contact | | `currency_id` | enum | ISO 4217 currency code | | `amount` | double | Transaction amount (always positive; type indicates direction) | | `status` | enum | Current status of the transaction | | `payment_method_type` | enum | Payment method used (for payments) | | `gateway` | string | Payment gateway/processor name (e.g., "stripe", "razorpay") | | `gateway_transaction_id` | string | Platform-specific transaction ID from the gateway | | `original_transaction_id` | string | For refunds/reversals, reference to the original payment | | `reference_number` | string | Human-readable reference number | | `description` | string | Human-readable description of the transaction | | `reason` | enum | Standardized reason code (primarily for refunds/credit notes) | | `reason_code` | string | Platform-specific reason code | | `metadata` | object | Additional platform-specific data | | `created_at` | string | Original transaction timestamp from platform (ISO 8601) | | `updated_at` | string | Last update timestamp from platform (ISO 8601) | ### Type Enum Values | Value | Description | | - | - | | `PAYMENT` | Contact payment received | | `REFUND` | Money returned to contact | | `CREDIT_NOTE` | Credit applied to contact account | | `FEE` | Processing fee or platform charge | | `CHARGEBACK` | Payment disputed and reversed by contact's bank | | `PAYOUT` | Transfer to merchant/vendor account | | `ADJUSTMENT` | Manual adjustment to balance | ### Status Enum Values | Value | Description | | - | - | | `REQUIRES_ACTION` | Transaction requires additional action before it can be completed | | `PENDING` | Transaction is being processed | | `AUTHORIZED` | Transaction has been authorized but not yet captured | | `PAID` | Transaction payment was successfully captured | | `FAILED` | Transaction failed to process | | `CANCELED` | Transaction was canceled before completion | | `REFUNDED` | Transaction funds were returned or credited back | | `UNKNOWN` | Status cannot be determined | | `REVERSED` | Transaction was reversed after completion | ### Payment Method Type Enum Values | Value | Description | | - | - | | `CARD` | Credit or debit card payment | | `BANK_TRANSFER` | Direct bank transfer or ACH | | `WIRE_TRANSFER` | Wire transfer | | `PAYPAL` | PayPal payment | | `APPLE_PAY` | Apple Pay | | `GOOGLE_PAY` | Google Pay | | `CHECK` | Check payment | | `CASH` | Cash payment | | `CRYPTO` | Cryptocurrency payment | | `OTHER` | Other payment method | | `UNKNOWN` | Payment method cannot be determined | ### Reason Enum Values | Value | Description | | - | - | | `CUSTOMER_REQUEST` | Contact requested the refund/credit | | `DUPLICATE` | Duplicate charge | | `FRAUD` | Fraudulent transaction | | `QUALITY_ISSUE` | Product or service quality issue | | `BILLING_ERROR` | Billing mistake | | `LOYALTY_DISCOUNT` | Loyalty program credit | | `PROMOTIONAL` | Promotional credit or discount | | `ADJUSTMENT` | Manual adjustment | | `OTHER` | Other reason | # Accounting Integrations Source: https://integrations.docs.commenda.io/accounting-integrations/accounting-integrations-overview RootFi' accounting integrations allow you to pull data directly from your customer’s accounting software in real-time. RootFi is a unified API provider designed to streamline accounting integrations. By simplifying the process of connecting to various accounting platforms, RootFi helps businesses access and manage their financial data with ease. The first step in working with RootFi is to connect an integration - this is the accounting platform whose data you want to retrieve and manipulate through RootFi's unified API. ### How do I set up and enable Accounting Integrations? Before you can begin pulling data via RootFi, it is recommended to test the integration by signing up with the accounting software provider of your choice, such as Zoho Books and Xero. Most platforms require OAuth credentials to enable you to connect to their APIs. To get started quickly you can **use RootFi's credentials**, which are provided in the RootFi dashboard. This enables you to enable an integration with a single toggle. When moving to production we recommend you set up your own OAuth credentials. We have compiled detailed information on how to get set up with all the platforms we support. # Fresh Books Source: https://integrations.docs.commenda.io/accounting-integrations/fresh-books Learn more about how to set up our Fresh Books integration. In order to get started using your own credentials for our Fresh Books integration, you will need to first register your Fresh Books application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your Fresh Books application 1. Go to [https://my.freshbooks.com/#/developer/](https://my.freshbooks.com/#/developer/) 2. Log in with your FreshBooks account and select 'Create New App'. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/freshbooks/create_new_app.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=f1783dc2666ef73039a232902176d3e1) 3. Complete the app registration form. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/freshbooks/app-form.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=00ee4ae738cd6d8111a3af5742238b38) 4. Choose the necessary permissions (scopes) for your app. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/freshbooks/add-scopes.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=5ec5d2622a8037247decef4ed384c4b7) 5. Add the redirect URI: [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url). ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/freshbooks/add-redirect-uri.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=29b1575760775c6502b3c853fab57917) 6. Save your settings. ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the Fresh books card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated on the Fresh API Console and click 'Save' # Microsoft Dynamics 365 Business Central Source: https://integrations.docs.commenda.io/accounting-integrations/microsoft-dynamics-365-business-central Learn how to set up our Microsoft Dynamics 365 Business Central integration. If you wish to set up Microsoft Dynamics 365 Business Central on the RootFi Portal, you will need to follow the steps outlined below. > [!NOTE] > > You will need to have verified your company domain in order for you to link your Microsoft Dynamics 365 Business Central integration ## 1. Create an App Follow the link [https://portal.azure.com/#view/Microsoft\_AAD\_RegisteredApps/ApplicationsListBlade](https://portal.azure.com/#view/Microsoft%5FAAD%5FRegisteredApps/ApplicationsListBlade) Click on the +New Registration, you will see a form like this. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/a5c5a30-Screenshot_2973.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=a028e7eff6c0db308581be398dbf6e4b) 1. Enter the user-facing display name for this application (this can be changed later). 2. Select Supported account types: Select Accounts in any organisational directory (Any Azure AD directory - Multi-tenant) and personal Microsoft accounts (e.g. Skype, Xbox). This allows RootFi to access data in Dynamics 365 Business Central. 3. Leave the **Redirect URI** empty. Business Central connects with your client ID and client secret, so RootFi does not use a redirect URI. 4. Now Click the Register Button, now you have created an app. 5. Below, You can see the newly created app. *** ## 2. Copy Client ID and Client Secret 1. Click on the newly created app, Go to the Overview section, you can see the Application Client ID. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/65ad5f0-Screenshot_2962.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=8191747c7a4c99e96b7bcbe082fd7cf1) *** ## 3. Generate and retrieve your client secret In the Azure Portal: 1. Select Certificates & secrets in the left menu. 2. Under Client secrets, click New client secret. 3. In the Add a client secret dialogue, update the following information: 4. Description: Enter a short description of your client secret to make it easier to find.\ Expires: Select the most appropriate option that complies with your company's security policy.\ Click Add. Your **client secret** is generated and displayed at the bottom of the page. > [!TIP] > > **Important** > The secret value won't be displayed again in full, so you must copy the value as soon as it gets generated. *** ## 4. Update access permissions Now update the access permissions for your application. These control the data that your app can access in Business Central. 1. Select API permissions in the left menu. 2. Under Configured permissions, click Add permission. 3. In the Request API permissions pane, scroll down and select Dynamics 365 Business Central. 4. Select Application permissions and also select the listed permissions:\ **API.ReadWrite.All**, **app\_access** and **Automation.ReadWrite.All**. ![Permissions](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/permissions.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=5b3ba4d8849055cc1c90c4030c24d7c5) 5. Click 'Add Permissions'. 6. Above the listed permissions, select Grant admin consent for Default Directory and then select Yes to confirm your change. This option might not be available for all subscription types ![Permissions Grant](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdBc/grant.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=703ff9aad8399023778b32f611cb9df8) *** ## 5. Enable the App Inside Business Central To complete your setup, enable the Azure Entra App **from within Business Central**: Navigate to the following link and sign into [https://businesscentral.dynamics.com](https://businesscentral.dynamics.com) 1. Click the **search icon** (🔍) in the top-right corner, search for **“Entra”**, and click **Microsoft Entra Applications**: ![Search Entra Applications](https://mintcdn.com/rootfi-commenda/K9cWVVWicIUdzprd/images/msdBc/entraSearch.png?fit=max\&auto=format\&n=K9cWVVWicIUdzprd\&q=85\&s=15f49dccf56a74263b11cc208d5f5c69) 2. Click **New**. ![Create New Entra](https://mintcdn.com/rootfi-commenda/iOGR2Lltsy8EHszS/images/msdBc/createNewEntra.png?fit=max\&auto=format\&n=iOGR2Lltsy8EHszS\&q=85\&s=3ac2517b6f92c802351a9458b400b562) 3. In the form that appears, paste your **Client ID** into the **Client ID / App ID** field. ![Fill Entra App Form Fields](https://mintcdn.com/rootfi-commenda/iOGR2Lltsy8EHszS/images/msdBc/fillEntraForm.png?fit=max\&auto=format\&n=iOGR2Lltsy8EHszS\&q=85\&s=176f306ee2b4f1d56bb09764db7b35f0) 4. From the **State** dropdown, select **Enabled**. 5. Scroll down to the permissions section and add the **D365 BUS FULL ACCESS** permission set. If you install the Commenda Custom API extension (step 7), also add **COMMENDA API**. ![Enable Administrator Permission](https://mintcdn.com/rootfi-commenda/iOGR2Lltsy8EHszS/images/msdBc/addEntraPermissionSet.png?fit=max\&auto=format\&n=iOGR2Lltsy8EHszS\&q=85\&s=f8dbba73629bb62c9a6d0f0eece37caa) 6. Click **Save** to apply the changes. ![Save Entra Form](https://mintcdn.com/rootfi-commenda/iOGR2Lltsy8EHszS/images/msdBc/saveEntraForm.png?fit=max\&auto=format\&n=iOGR2Lltsy8EHszS\&q=85\&s=cd821b723ad55724b26184a2eea61a4c) 7. Your Azure App is now authorized inside Business Central and ready for use with RootFi. *** ## 6. Get Tenant ID and Env Name from Admin Center You will need to enter your Client Credentials, Tenant ID and Env name in the RootFi connect screen. 1. To get the Tenant ID and Env name, navigate to the BC dashboard, click on settings and then click on 'Admin Center'. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdBc/admin_center.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=594e4c20f3f0df0194a23f51a43c90f5) 2. Select the environment you want to connect. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdBc/envs.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=e179e2d909beb4d9416fe1cda94b8f2e) 3. Copy the name of the environment and the tenant id from the URL. Use the following pattern to get the tenant ID of your Business Central: [https://businesscentral.dynamics.com/\[TENANT\_ID\]/\[ENVIRONMENT\_NAME](https://businesscentral.dynamics.com/\[TENANT_ID]/\[ENVIRONMENT_NAME)] ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdBc/env_name_tenant.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=53ba9d118f1326c07972714cd032d7eb) *** ## 7. (Optional) Install the Commenda Custom API extension The **Commenda Custom API** extension is only required for some additional features that Business Central's standard APIs do not support. The rest of the integration works without it. If you are unsure whether you need this step, reach out to the Commenda integrations team. > [!NOTE] > > The extension requires Business Central application version **27.3** or later. You install it from the Business Central admin center, so you need a Microsoft Entra admin role that can access it, such as Dynamics 365 administrator or Global administrator. 1. Download [Commenda\_Business\_Central\_Extension\_1.2.0.0.app](https://integrations.commenda.io/downloads/business-central/Commenda_Business_Central_Extension_1.2.0.0.app). 2. Open the Business Central admin center, go to **Environments**, and click the name of the environment you want to connect. ![Admin Center Environments](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/adminCenterEnvironments.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=6898b6af3a19561950a3970ec7e47423) 3. Click **Apps** at the top of the environment page. ![Admin Center Environment Details](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/adminCenterEnvironmentDetails.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=8c64d808687eac44902b98dcf757159c) 4. On the **Manage apps** page, click **Install Extension**. ![Admin Center Manage Apps](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/adminCenterManageApps.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=2cf9e7945f3803b6694cc5edf5ddd9ce) 5. In the **Install Per-Tenant Extension** panel, click **Choose file** and select the downloaded `.app` file. Keep **Deployment schedule** as **Immediate** and **Sync mode** as **Add**, select **I accept the terms above**, and click **Schedule Install**. ![Install Per-Tenant Extension](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/adminCenterInstallExtension.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=63e449010ad0d7805d84cf8bebe059e9) 6. Installation runs in the background, and you can track it under **Operations**. Once it finishes, **Commenda Custom API** appears in **Manage apps** with the installed version. ![Commenda Custom API Installed](https://mintcdn.com/rootfi-commenda/e--USPkkL-OO-TuG/images/msdBc/adminCenterExtensionInstalled.png?fit=max\&auto=format\&n=e--USPkkL-OO-TuG\&q=85\&s=0bf2e31802ed45ceabf00c1e26af5814) 7. Assign the **COMMENDA API** permission set to the account that RootFi authenticates as — the Microsoft Entra application you enabled in step 5. Open its permission sets and add a line for **COMMENDA API**. ![Commenda API Permission Set](https://mintcdn.com/rootfi-commenda/1J8Grb8uVkyMZoga/images/msdBc/commendaApiPermissionSet.png?fit=max\&auto=format\&n=1J8Grb8uVkyMZoga\&q=85\&s=556b2ae293a901092764451aaa0fc6c2) > [!TIP] > > **Upgrades** > To move to a newer release, install the new `.app` the same way from **Manage apps**. Business Central replaces the existing extension in place, so there is no need to uninstall first, and your permission set assignment is preserved. Use only the admin center to manage this extension, not the **Extension Management** page inside Business Central. *** # Microsoft Dynamics 365 F&O Source: https://integrations.docs.commenda.io/accounting-integrations/microsoft-dynamics-365-f&o Learn how to set up our Microsoft Dynamics 365 F&O integration. If you wish to set up Microsoft Dynamics 365 F\&O on the RootFi Portal, you will need to follow the steps outlined below. *** ## Setting up OAuth Credentials ### Part 1: Create an App Follow the link [https://portal.azure.com/#view/Microsoft\_AAD\_RegisteredApps/ApplicationsListBlade](https://portal.azure.com/#view/Microsoft_AAD_RegisteredApps/ApplicationsListBlade) Click on the +New Registration, you will see a form like this. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/a5c5a30-Screenshot_2973.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=a028e7eff6c0db308581be398dbf6e4b) 1. Enter the user-facing display name for this application (this can be changed later). 2. Select Supported account types: Select Accounts in any organisational directory (Any Azure AD directory - Multi-tenant) and personal Microsoft accounts (e.g. Skype, Xbox). This allows RootFi to access data in Dynamics 365 F\&O. 3. In the Redirect URI, select the dropdown value as Web and in the value, paste the url, [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) 4. Now Click the Register Button, now you have created an app. 5. Below, You can see the newly created app. ### Part 2: Copy Client ID and Client Secret 1. Click on the newly created app, Go to the Overview section, you can see the Application Client ID similar to 38b55dff-140c-4602-abb5-d13dc644. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/65ad5f0-Screenshot_2962.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=8191747c7a4c99e96b7bcbe082fd7cf1) ### Part 3: Generate and retrieve your client secret In the Azure Portal: 1. Select Certificates & secrets in the left menu. 2. Under Client secrets, click New client secret. 3. In the Add a client secret dialogue, update the following information: 4. Description: Enter a short description of your client secret to make it easier to find.\ Expires: Select the most appropriate option that complies with your company's security policy.\ Click Add. Your **client secret** is generated and displayed at the bottom of the page. > [!TIP] > > **Important** > > The secret value won't be displayed again in full, so you must copy the value as soon as it gets generated. ### Part 4: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard. 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with. 3. Click the 'Set Up' button on the MS Dynamics 365 card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' that you generated and click 'Save'. ## Adding OAuth Credentials to Clients F\&O Account These steps have to be followed by the end-user who is connecting their F\&O account to RootFi. ### Part 1: Set up the F\&O account to access the data. When your customer is connecting their MSD F\&O account to RootFi, they will need to enter the client credentials in their F\&O dashboard to allow RootFi to access the data. 1. Login to the F\&O dashboard and navigate to Microsoft Entra ID applications. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdF\&O/navigateDashboard.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=cb2eae1c261d6b2ef409d1b812a5822a) 2. Click on '+New' and enter the client id you copied from the Azure portal, enter a name and set the User ID to 'Admin'. Enter '8f09f705-3d36-4cc9-84c2-8091e362c759' as the client id if you are using RootFi credentials. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdF\&O/dashboard.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=5e6beaeca48cebbaceee2134a8b46e21) ### Part 2: Setting up the integration Using RootFi Connect You will need to enter your F\&O site url in the RootFi connect screen. 1. To get the site url, navigate to the F\&O dashboard and copy the url from the address bar. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdF\&O/url.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=ffd47a5b011aafd59067d6a5cc8b596b) 2. In the RootFi SDK screen, paste the site url of your F\&O dashboard without the 'https\://' and 'opearations.dynamics.com' part. ![Client ID MS Dynamics](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/msdF\&O/sdk.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=3fe54483854253bd4aa326d42821718b) # MYOB Business Source: https://integrations.docs.commenda.io/accounting-integrations/myob-business Learn more about how to set up our MYOB Business integration. In order to get started using your own credentials for our MYOB Business integration, you will need to first register your MYOB application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your MYOB Business application 1. Go to [MYOB Developer Portal](https://my.myob.com.au/Bd/pages/DevAppList.aspx) 2. Sign in using your MYOB credentials, and click the ‘Register App' button in Developer Tab. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/f9d021f-Screenshot_2023-03-08_at_2.35.28_PM.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=99b08142593bf94da02ee013ca03dd55) 1. Enter all the details of the App 1. Redirect URI: [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/df9d3fe-image.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=a3cd7a71cddd5fbcb109b827c19dc137) 1. Copy the Key and Secret of the registered app ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the MYOB card. 4. Enter the 'Client ID' and 'Client Secret' which you copied from MYOB Dev platform # Odoo Accounting Source: https://integrations.docs.commenda.io/accounting-integrations/odoo-accounting Learn how to set up our Odoo Accounting integration. In order to get started using your own credentials for our Odoo Accounting integration, your customer will need to first create an API Key for their Odoo application. After that, they will need to enter their Odoo credentials on RootFi when prompted during the Odoo integration setup on RootFi's Connect Link. These steps are elaborated upon in detail below. *** ### Part 1: Register Odoo application 1. Go to your Odoo Dashboard. 2. Click on top right corner (on the user name) and select Preferences. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/bede84b-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=2233706095a0d540837cef770dc8bb92) 1. Go to Account Security tab and create your first API key. 2. Enter the name of the key and copy the API key generated. ### Part 2: Setting up the integration Using RootFi Connect When your customer is connecting their Odoo account to RootFi, they will need to enter their Odoo credentials on RootFi's invite link setup. They will need to fill the following information: 1. **Domain Name**: The url for your Odoo dashboard. For Example: `RootFi.odoo.com`. 2. **Database Name**: To find your domain name, click on 'User Profile' on the top right corner and click on 'My databases'. ![](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/odoo/profile.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=a3dfb01ef0d907907a5729c67b3d6c7d) ![](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/odoo/databases.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=fc449805c185f2fe076e6aa6e1f06fd7) 3. **Email Address**: The email with which you will login to your Odoo Dashboard. 4. **API Key**: The key generated in the above steps. ![](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/odoo/connect.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=4ca88e4248dcf7d7cb08cc9344a13de6) # Oracle NetSuite Source: https://integrations.docs.commenda.io/accounting-integrations/oracle-netsuite Learn how to set up our Oracle NetSuite integration. There are two ways to connect NetSuite. Use the one that matches the fields shown in your Connect flow. * **Token-Based Authentication**: Consumer Key, Consumer Secret, Token ID and Token Secret * **[OAuth 2.0 Client Credentials (Latest)](#oauth-2-0-client-credentials-latest)**: NetSuite Account ID and Certificate ID ## Pre-requisites Before setting up the integration, make sure you meet the following requirements: * You possess **Administrator** permissions in your company’s NetSuite instance or have access permissions shared with you by another user. 💡 The standard Administrator role is available in the list of roles on the Manage Roles page. ## Enable Features Do this before installing the bundle. Navigate to **Setup** > **Company** > **Enable Features** and turn on: **1. Token-Based Authentication and OAuth 2.0** On the **SuiteCloud** subtab, under Manage Authentication. ![Untitled](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/63b17c4-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=21e34491ef010b08c6149a20c7436743) ![Untitled](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/df5b5d8-image.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=d5cd65e6cf2828f5029c66e89922c943) **2. REST Web Services** On the **SuiteCloud** subtab, under SuiteTalk (Web Services). ![Untitled](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/6750409-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=75ac17bb8c405184df7a93f24f911bf9) **3. Client SuiteScript and Server SuiteScript** On the **SuiteCloud** subtab, under SuiteScript. ![Untitled](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/2cd1bac-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=f2bd1ea255d6ebeed769439553c5e723) > [!WARNING] > > If any of these are off, installing the bundle in the next section fails with NetSuite's generic **"An unexpected error has occurred"** page. The error comes from NetSuite, not from us, and it does not say which feature is missing — so confirm all of the above are enabled before you install. ## Install the Bundle **1. First Step** In your NetSuite account, navigate to **Customization** > **SuiteBundler** > **Search & Install Bundles** > **List** or search for Search & Install Bundles in the Search bar. ![Untitled](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/Untitled.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=d47470cfed2738b3036ee4365362643a) **2. Second Step** Search for the **Commenda Technologies Inc** bundle or bundle ID **565042** using the Keyword box. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%201.png) **3. Third Step** Select the bundle and click **Install**. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%202.png) **4. Fourth Step** The bundle will begin installing and you maybe directed to the Installed Bundles page. It may take up to 5 minutes to install. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%203.png) ## Create a new integration to generate the Consumer Key and Consumer Secret **1. First Step** Navigate to **Setup** > **Integration** > **Manage Integrations** > **New** to create a new integration. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%204.png) **2. Second Step** Create an integration with the below details: * Any value can be populated in the **NAME** field * The **CONCURRENCY LIMIT** should be left unpopulated * Ensure the **REST WEB SERVICES box is checked** under SCOPE * The **TOKEN-BASED AUTHENTICATION** and **TBA AUTHORIZATION FLOW** boxes should be checked * Fill in the **CALLBACK URL** and **REDIRECT URI** with a value of \[[ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url)]\([ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url)) ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%205.png) **3. Third Step** Save the integration to generate the **Consumer Key** and **Consumer Secret**. **This will only be shown once, so store them in a secure place.** ![consumer key and consumer secret screenshot.png](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/consumer_key_and_consumer_secret_screenshot.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=fad85bd0cea8127f79df65dbefafb120) **4. Fourth Step** The bundle will begin installing and you maybe directed to the Installed Bundles page. It may take up to 5 minutes to install. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%203.png) ## Assign a user to the role **1. First Step** Navigate to **Setup** > **Users/Roles** > **Manage Users** or search **Manage Users** in the Search bar. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%206.png) **2. Second Step** In the Manage Users page, either select a user to assign the Role to. 💡 Most users use an existing user (often yourself) so that an additional NetSuite seat is not consumed. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%207.png) **3. Third Step** In the user's employee record, click **Edit** and go to the **Access** tab. In your Access tab, go to Roles and select **RootFi Role Permission**. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%208.png) ## Create an access token to get your Token ID and Secret **1. First Step** In your **Setup** tab, go to **User Roles** > **Access Tokens** > **New** or search **New Access Token** in the search bar to begin creating a New Access Token. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%209.png) **2. Second Step** Select the Application Name (name of the integration you created in Step 2), User and Role (RootFi Role Permission) and click **Save** to generate a new access token. ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%2010.png) **3. Third Step** Copy the **Token ID** and **Token Secret** provided. **This will only be shown once, so store them in a secure place.** ![token id and token secret screenshot.png](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/token_id_and_token_secret_screenshot.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=0eec7a4cce0bc15b2446fb6900dc5bbc) ## Finding your NetSuite Account ID **1. First Step** Log into your NetSuite portal **2. Second Step** Copy the subdomain of the URL at the top of your browser and enter it within the Connect Link. In the below screenshot it is **`8635772-sb1`.** ![Screenshot 2024-04-19 at 2.53.59 PM.png](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/Screenshot_2024-04-19_at_2.53.59_PM.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=57f7a589107a5ed4d38193c324b83040) ## Enter credentials in the Connect flow ![Untitled](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%2011.png) * **Consumer Key**: Confirmation screen after creating the integration (Step 2) * **Consumer Secret**: Confirmation screen after creating the integration (Step 2) * **Token ID**: Confirmation screen after creating your Access Token (Step 3) * **Token Secret**: Confirmation screen after creating your Access Token (Step 3) ## OAuth 2.0 Client Credentials (Latest) To connect with OAuth 2.0 Client Credentials, you need: * NetSuite Account ID * Certificate ID ### Enable Features Do this before installing the bundle. Navigate to **Setup** > **Company** > **Enable Features** and turn on: **1. OAuth 2.0** On the **SuiteCloud** subtab, under Manage Authentication. ![Enable Features](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/63b17c4-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=21e34491ef010b08c6149a20c7436743) ![OAuth 2.0](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/df5b5d8-image.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=d5cd65e6cf2828f5029c66e89922c943) **2. REST Web Services** On the **SuiteCloud** subtab, under SuiteTalk (Web Services). ![REST Web Services](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/6750409-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=75ac17bb8c405184df7a93f24f911bf9) **3. Client SuiteScript and Server SuiteScript** On the **SuiteCloud** subtab, under SuiteScript. ![SuiteScript](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/2cd1bac-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=f2bd1ea255d6ebeed769439553c5e723) ### Install or update the bundle **1. Open Search & Install Bundles** Navigate to **Customization** > **SuiteBundler** > **Search & Install Bundles** > **List** or search for Search & Install Bundles in the Search bar. ![Search & Install Bundles](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/Untitled.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=d47470cfed2738b3036ee4365362643a) **2. Find the bundle** Search for the **Commenda Technologies Inc** bundle or bundle ID **565042** using the Keyword box. ![Find the bundle](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%201.png) **3. Install** Select the bundle and click **Install**. ![Install](https://mintlify.s3.us-west-1.amazonaws.com/rootfi-commenda/images/netsuite/Untitled%202.png) **4. Wait for the install** The bundle will begin installing and you may be directed to the Installed Bundles page. It may take up to 5 minutes to install. **5. Update the bundle** If the bundle is already installed, click the gear icon next to **Commenda Technologies Inc** and select **Update**. ![Installed Bundles](https://mintcdn.com/rootfi-commenda/tjrCxnP7uXmdK5Z9/images/netsuite/installed-bundles.png?fit=max\&auto=format\&n=tjrCxnP7uXmdK5Z9\&q=85\&s=364ccb2279cf659974226da3609eb8b7) ### Find your NetSuite Account ID Copy the subdomain of your NetSuite URL. In the below screenshot it is **`8635772-sb1`**. ![NetSuite Account ID](https://mintcdn.com/rootfi-commenda/JIWggfJznJdOtanp/images/netsuite/Screenshot_2024-04-19_at_2.53.59_PM.png?fit=max\&auto=format\&n=JIWggfJznJdOtanp\&q=85\&s=57f7a589107a5ed4d38193c324b83040) ### Assign the Commenda role to a user **1. Open the user** Navigate to **Setup** > **Users/Roles** > **Manage Users**, select the user and click **Edit**. **2. Add the role** On the **Access** tab, under **Roles**, add **Commenda Technologies, Inc.** and click **Save**. ### Create the client credentials mapping **1. Download the Commenda certificate** In the Connect flow, enter your NetSuite Account ID and click **Download Commenda certificate**. Keep the Connect flow open. **2. Open OAuth 2.0 Client Credentials Setup** In NetSuite, navigate to **Setup** > **Integration** > **Manage Authentication** > **OAuth 2.0 Client Credentials (M2M) Setup** and click **Create New**. ![OAuth 2.0 Client Credentials Setup](https://mintcdn.com/rootfi-commenda/tjrCxnP7uXmdK5Z9/images/netsuite/m2m-setup-list.png?fit=max\&auto=format\&n=tjrCxnP7uXmdK5Z9\&q=85\&s=935e39e1b25af1edab08639a873c9f60) **3. Create the mapping** * **Entity**: the user you assigned the role to * **Role**: **Commenda Technologies, Inc.** * **Application**: **Commenda OAuth 2.0 M2M** * **Certificate**: the certificate you downloaded Click **Save**. ![Create a New Client Credentials Mapping](https://mintcdn.com/rootfi-commenda/tjrCxnP7uXmdK5Z9/images/netsuite/m2m-create-mapping.png?fit=max\&auto=format\&n=tjrCxnP7uXmdK5Z9\&q=85\&s=6c3a0facee82d3b6ab740d5ed28baa8c) **4. Copy the Certificate ID** Copy the **Certificate ID** of the new mapping. ![Certificate ID](https://mintcdn.com/rootfi-commenda/tjrCxnP7uXmdK5Z9/images/netsuite/m2m-certificate-id.png?fit=max\&auto=format\&n=tjrCxnP7uXmdK5Z9\&q=85\&s=ed088f3ab601cf78c284d9bcfa5ad817) ### Enter details in the Connect flow Back in the Connect flow, paste the **Certificate ID** and click **Continue**. ![Connect flow](https://mintcdn.com/rootfi-commenda/tjrCxnP7uXmdK5Z9/images/netsuite/m2m-connect-form.png?fit=max\&auto=format\&n=tjrCxnP7uXmdK5Z9\&q=85\&s=61a82011a09fee582b54b3293a5f5d28) > [!NOTE] > > If the certificate on the mapping is replaced or revoked, its Certificate ID stops working. Reconnect with the new Certificate ID. # Puzzle Source: https://integrations.docs.commenda.io/accounting-integrations/puzzle Learn more about how to set up our Puzzle integration. Puzzle uses OAuth2, so the integration needs a Client ID and Client Secret. Puzzle's app registration is not self-serve — you have to request OAuth credentials from Puzzle support. To get started quickly you can instead use RootFi's credentials, which enables the integration with a single toggle. These steps are elaborated upon in detail below. *** ### Part 1: Get your Puzzle OAuth credentials 1. Contact Puzzle support and request OAuth credentials (Client ID and Client Secret) for your application. 2. Puzzle registers the redirect URI on their side and does not allow it to be changed, so ask them to register the [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url). ### Part 2: Enter your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard. 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with. 3. Open the Puzzle integration, enter the 'Client ID' and 'Client Secret' provided by Puzzle support and click 'Save authentication'. To use RootFi's credentials instead, turn on the 'Use RootFi Credentials' toggle. 4. Enable the integration using the 'Integration status' toggle. ![](https://mintcdn.com/rootfi-commenda/oNfTWEU-xjnPsFhv/images/puzzle/dashboard_credentials.png?fit=max\&auto=format\&n=oNfTWEU-xjnPsFhv\&q=85\&s=604be6eeecf0a349c8f68b1e40163d12) ### Part 3: Connecting a company When your customer connects their Puzzle account through RootFi's Connect Link, they log in to Puzzle and approve access. If their Puzzle login has access to more than one company, they are then asked to pick the one to sync; the selection is stored on the connection as the `organization_id` connection variable. # Quickbooks Online Source: https://integrations.docs.commenda.io/accounting-integrations/quickbooks-online Learn how to set up our Quickbooks Online integration. Before you can start pulling data from customers who use QuickBooks Online for their accounting, you will need to set up the QuickBooks Online integration. There are two integrations available: 1. QuickBooks Online Sandbox (for development and testing) 2. QuickBooks Online (for production) *** ### Overview In order to set up the integration there are a few steps that must first be completed. 1. Create an app in the [Intuit Developer Portal](https://developer.intuit.com/app/developer/homepage). 2. Complete the app assessment questionnaire. 3. Once your app is approved you will be able to access your production keys. 4. Add your secure keys to the RootFi dashboard and start pulling data! We will do a detailed breakdown of these steps in the sections below: ### Part 1 - Create your Quickbooks Application When you create a QuickBooks Online app in the Intuit Developer Portal, you can choose to configure it for the sandbox environment or production environment. The app will have two sets of keys: development and production. We recommend first configuring your app for the sandbox integration so you can test thoroughly before going live. You can access your dev keys in the Development Settings section of your Quickbooks dashboard. Perform these actions in the [Intuit Developer Portal](https://developer.intuit.com/app/developer/homepage). 1. Click on Dashboard from the nav bar at the top of the screen. 2. Select Create an app. 3. Select QuickBooks Online and Payments, and enter your app name. 4. Under Select a scope, choose com.intuit.quickbooks.accounting. 5. Click Create app. 6. Configure the app to connect to the sandbox environment: 1. In the left menu, click on Development Settings > Keys & credentials. 2. In the Redirect URIs section, select 'Add URI'. 3. In the 'Link' box on top, enter the RootFi URI: [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) 7. Then click Save. 8. Your development keys (client ID and client secret) will be displayed in the 'Keys' section at the top of the page. 9. Copy these keys and simply paste them into the Quickbooks Sandbox integration on the RootFi Platform. ### Part 2 - Completing the App Assessment Questionnaire 1. Select Production Settings > Keys & Credentials, from the nav bar on the left. 2. Then theGet your app's production keys page will come up. 3. Enter the information required in the Add details about your app section: ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/e3c3e8b-image.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=fb0e8ba53fedfaa033f428e66e9ee889) 4. Complete the App Assessment Questionnaire as described in the previous section. 5. Once you complete all the steps and your questionnaire responses have been approved, the page will update to display your production keys. 6. Go to Production Settings > Keys & Credentials, and configure your app to connect to RootFi: 1. Go to the Redirect URIs section, and select Add URI. 2. In the top Link box, enter the RootFi Production URI: Need to add 7. Then click 'Save'. ### Part 3 - Enter your Client ID and Client Secret on the RootFi Dashboard To activate your Quickbooks integration, follow these steps on the RootFi platform: 1. Log in to the RootFi dashboard. 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with. 3. Click the 'Set Up' button which is present on the Quickbooks card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated on the Intuit Developer Portal and click 'Save'. # Rillet Source: https://integrations.docs.commenda.io/accounting-integrations/rillet Learn how to set up our Rillet integration. Rillet uses API key authentication, so no OAuth application or partner credentials are required. Your customer will need to create an API key in Rillet and enter it on RootFi when prompted during the Rillet integration setup on RootFi's Connect Link. These steps are elaborated upon in detail below. *** ### Part 1: Get API Key 1. Login to your Rillet dashboard and go to Settings. 2. Under Organization, select 'API Access'. Click 'Create API key', enter a name for the key and copy the generated key. ![](https://mintcdn.com/rootfi-commenda/Xu3fIAsfuCINZAod/images/rillet/api_keys.png?fit=max\&auto=format\&n=Xu3fIAsfuCINZAod\&q=85\&s=26fcbd3162a2955c32c0c84a00fdcdf2) > [!NOTE] > > The API key must be Active, and must not be Read-only if you intend to write data back to Rillet through RootFi. ### Part 2: Setting up the integration Using RootFi Connect When your customer is connecting their Rillet account to RootFi, they will need to enter the following on RootFi's invite link setup: 1. **API Key**: The key generated in the above steps. ![](https://mintcdn.com/rootfi-commenda/qtNr2Yjm08S9syMQ/images/rillet/connect.png?fit=max\&auto=format\&n=qtNr2Yjm08S9syMQ\&q=85\&s=4ad4976b44567a773803d769d99ed4e2) If the API key has access to more than one Rillet subsidiary, the customer is then asked to pick the subsidiary to sync. The selected subsidiary is stored on the connection as the `organization_id` connection variable. If the key has access to a single subsidiary, it is selected automatically and the connection completes right away. # Wafeq Source: https://integrations.docs.commenda.io/accounting-integrations/wafeq Learn how to set up our Wafeq integration. In order to get started using your own credentials for our Wafeq integration, your customer will need to first create an API Key for their Wafeq application. After that, they will need to enter their API Key on RootFi when prompted during the Wafeq integration setup on RootFi's Connect Link. These steps are elaborated upon in detail below. *** ### Part 1: Get API Key 1. Login to your [Wafeq Dashboard](https://app.wafeq.com/c/50716/api-keys). 2. Navigate to API Keys under Developer on the sidebar. Click 'Create Key', enter a name for the key and click 'Create'. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/wafeq_api_key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=7ea26b6c55a4a67ffd2ed0c19a864b44) To get Wafeq credentials, you have to contact Wafeq and request them for Developer Keys. To get started quickly, you can use just use RootFi credentials. ### Part 2: Setting up the integration Using RootFi Connect When your customer is connecting their Wafeq account to RootFi, they will need to enter their API Key on RootFi’s invite link setup. 1. **API Key**: The key generated in the above steps. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/wafeq_connection.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=8a667f733e3f64ec9815e52c15dcf9f8) # Xero Source: https://integrations.docs.commenda.io/accounting-integrations/xero Learn how to set up our Xero integration. To start using our Xero integration, you need to first register your Xero application, and then enter your Client ID and Client Secret on the RootFi dashboard. These steps are outlined in greater detail below. *** ### Step 1 - Register your Xero App 1. Go to [https://developer.xero.com](https://developer.xero.com) 2. Log in using your Xero credentials. 3. In the My Apps tab, click the 'New App' button on the top right corner of the screen. 4. In the ‘Redirect URIs’ field, enter [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) 5. Enter the following information in the 'Add a New App' dialogue: ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/b587acd-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=101a4016c65f551ed4bbb3fde57e510b) 6. Click 'Create App'. ### Step 2 - Get access to your Secure Keys (Client ID and Client Secret) 1. In the 'My Apps' tab, select the app you just created. 2. Select configuration from the sidebar menu. 3. Then Click the 'Generate Secret' button. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/image1.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=f01c002328a35891cbc51e0e093ba66a) 4. Copy the Client ID and Client Secret. ## Step 3: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard. 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with. 3. Click the 'Set Up' button on the Xero card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' that you generated and click 'Save'. # Zoho Books Source: https://integrations.docs.commenda.io/accounting-integrations/zoho-books Learn more about how to set up our Zoho Books integration. In order to get started using your own credentials for our Zoho Books integration, you will need to first register your Zoho Books application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your Zoho Books application 1. Go to [https://api-console.zoho.com/](https://api-console.zoho.com/) 2. Sign in using your Zoho Books credentials, and click the ‘Get Started' button. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/b0f2355-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=56ffc20db29da16221eecefe41be8dfa) 3. On the page titled ‘ Choose Client Type’ select ‘Server-Based Applications’. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/62fdbcb-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=76c79777dbba7bc66d3e56aabad4c386) 4. The ‘Create New Client’ page will be displayed. Here you must enter the following details: * In the ‘Client Type’ list, select ‘Server-based Applications’. * For the ‘Client Name’ field, enter your company's name. * In the ‘Homepage URL’ field, enter your company's website. * In the ‘Authorized redirect URIs’ field, enter [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/image.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=84074b32d98295c9ff08defc2663bc3b) 5. After you click ‘Create’ and the page refreshes, you should select the ‘Client Secret’ tab. Here you will find the secure keys that you need to enter on RootFi’s dashboard in order to activate the Integration. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/c2e3afb-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=dc89040f80dd8c5fdbef2322755d46b6) 6. Finally, you select the ‘Settings tab’, enable the regions where you have customers, and check the box which says ‘Use the same OAuth credentials for all data centres.' ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/26539e4-image.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=71678bd559f04b7d85c002b08b1faf68) ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the Zoho books card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated on the Zoho API Console and click 'Save' # Get a pipeline Source: https://integrations.docs.commenda.io/api-reference/crm/get-a-pipeline /openapi_v4_core.json get /v4/core/companies/{companyId}/pipelines/{id} # Get a task Source: https://integrations.docs.commenda.io/api-reference/crm/get-a-task /openapi_v4_core.json get /v4/core/companies/{companyId}/tasks/{id} # List pipelines Source: https://integrations.docs.commenda.io/api-reference/crm/list-pipelines /openapi_v4_core.json get /v4/core/companies/{companyId}/pipelines # List tasks Source: https://integrations.docs.commenda.io/api-reference/crm/list-tasks /openapi_v4_core.json get /v4/core/companies/{companyId}/tasks # Overview Source: https://integrations.docs.commenda.io/api-reference/v4/unified/tasks/overview The Tasks data model. The Task data model. ## Attributes ### Tasks Attributes | Property | Type | Description | | - | - | - | | `rootfi_id` | integer | | | `rootfi_created_at` | string | | | `rootfi_updated_at` | string | | | `rootfi_integration_type` | enum | | | `platform_id` | string | | | `subject` | string | | | `description` | string | | | `status` | enum | | | `priority` | string | | | `due_date` | string | | | `completed_at` | string | | | `owner_id` | string | | | `account_id` | string | | | `contact_id` | string | | | `opportunity_id` | string | | | `lead_id` | string | | | `created_at` | string | | | `updated_at` | string | | # CRM Integrations Source: https://integrations.docs.commenda.io/crm-integrations/crm-integrations-overview RootFi’s crm integrations allow you to pull data directly from your customer’s crm software in real-time. RootFi is a unified API provider designed to streamline CRM (Customer Relationship Management) integrations. By simplifying the process of connecting to various crm platforms, RootFi helps businesses access and manage their financial data with ease. The first step in working with RootFi is to connect an integration - this is the crm platform whose data you want to retrieve and manipulate through RootFi's unified API. ### How do I set up and enable CRM Integrations? Before you can begin pulling data via RootFi, it is recommended to test the integration by signing up with the crm software provider of your choice, such as HubSpot and Salesforce. Most platforms require OAuth credentials to enable you to connect to their APIs. To get started quickly you can use **RootFi's credentials**, which are provided in the RootFi dashboard. This enables you to enable an integration with a single toggle. When moving to production we recommend you set up your own OAuth credentials. We have compiled detailed information on how to get set up with all the platforms we support. # Hubspot Source: https://integrations.docs.commenda.io/crm-integrations/hubspot Learn more about how to set up our Hubspot integration. In order to get started using your own credentials for our Hubspot integration, you will need to first register your Hubspot application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your Hubspot application 1. Go to [https://app.hubspot.com/developer/](https://app.hubspot.com/developer/) 2. Navigate to Apps in the sidebar and click 'Create app' button. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/hubspot/create-app-button.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=55565012c3a06daf90eaff14763ec9fa) 3. Fill in the basic information in App Info tab. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/hubspot/basic_info.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=b245625396dca68011f45c9579866902) 4. Go to the ‘Auth’ tab and fill in the following fields: * **Redirect URL**: This is the URL where the user will be redirected after they have authorized the app. Use [ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) as the redirect URL. * **Scopes**: Select the scopes you need for your integration. For RootFi, you will need the following scopes: ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/hubspot/scopes_list.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=8435916a5e73b49c449d83a210225478) 5. Click on the 'Create App' button to save the changes. 6. Visit the 'Auth' tab again and copy the 'Client ID' and 'Client Secret' values. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/hubspot/auth_cred.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=07d7cbdddfbf1d22bf984c835a26a3d7) ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the Hubspot card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated on the Hubspot Developer App and click 'Save' *** ### Supported data models (V4) HubSpot is available as a CRM source on the V4 Unified API. The following data models are synced: | Data model | Reference | | - | - | | Contacts | [Contacts](/api-reference/v4/unified/contacts/overview) | | Companies | [Companies](/api-reference/v4/unified/companies/overview) | | Owners | [Owners](/api-reference/v4/unified/owners/overview) | | Leads | [Leads](/api-reference/v4/unified/leads/overview) | | Opportunities | [Opportunities](/api-reference/v4/unified/opportunities/overview) | | Pipelines | [Pipelines](/api-reference/v4/unified/pipelines/overview) | | Notes | [Notes](/api-reference/v4/unified/notes/overview) | | Tasks | [Tasks](/api-reference/v4/unified/tasks/overview) | Contacts expand into `addresses`, `phone_numbers`, and `external_links` child records via the `expand` query parameter. # Salesforce Source: https://integrations.docs.commenda.io/crm-integrations/sales-force Learn more about how to set up our Salesforce integration. In order to get started using your own credentials for our Salesforce integration, you will need to first register your Salesforce application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your Salesforce application 1. Go to [https://login.salesforce.com/](https://login.salesforce.com/) and sign in to your Salesforce account. 2. Click on the gear icon in the top right corner of the page and select ‘Open Advanced Setup’. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/open_setup.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=833c87a71f7908dfd663bcae335ec243) 3. Navigate to "PLATFORM TOOLS" >> “Apps” >> “App manager”. Click on the ‘New Connected App’ button on the top right corner of the page. ![](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/new_connected_app.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=0ae044bf0a9aa1bbf1d8231c4bb75ac6) 4. You would be redirected to a page where you need to fill in the details of your application. ![image](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/salesforce_empty_form.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=a7ebcd81cf93bb90a885ec48b44f4d6f) 5. Fill in the basic information for your application: ![image](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/basic_info.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=2db16a1ec436e08c597217c86ac87167) 6. Enable OAuth settings by scrolling down to the ‘API (Enable OAuth Settings)’ section and checking the box. ![image](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/api_settings_section.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=71a340f9838a80f394a32f3d2f8f97a4) * Keep '[ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url)' as the Callback URL. * Select the OAuth scopes you need. For RootFi, you need to select the following scopes: * Manage user data via APIs (api) * Perform requests at any time (refresh\_token, offline access) * Access unique user identifiers (openid) * Incase you need full access to all the data, you can select the 'Full access (full)' scope. * Click on the 'Add' button to add the selected scopes. 7. **Disable Require Proof Key for Code Exchange (PKCE) Extension for Supported Authorization Flows:** This option is enabled by default. You need to disable it. 8. **Disable Require Secret for Refresh Token Flow:** This option is enabled by default. You need to disable it. 9. **Enable Introspect All Tokens:** This option is disabled by default. You need to enable it. 10. Click on the 'Save' button which will save the changes and redirect you to the application details page. It can take upto 10 minutes for the changes to reflect. 11. On the App Manager page, click on the app you just created. You will be redirected to the app details page. ![image](https://mintcdn.com/rootfi-commenda/qu4Xde-IYZdny7Px/images/crm/salesforce/list_apps_screen.png?fit=max\&auto=format\&n=qu4Xde-IYZdny7Px\&q=85\&s=a29ebe53d364271340aae876842bfa89) 12. On the app details page, you will find the **Consumer Key** and **Consumer Secret** which you will need to enter on the RootFi dashboard. ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the Salesforce card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated on the Salesforce App Manager and click 'Save' *** ### Supported data models (V4) Salesforce is available as a CRM source on the V4 Unified API. The following data models are synced: | Data model | Reference | | - | - | | Contacts | [Contacts](/api-reference/v4/unified/contacts/overview) | | Companies | [Companies](/api-reference/v4/unified/companies/overview) | | Owners | [Owners](/api-reference/v4/unified/owners/overview) | | Leads | [Leads](/api-reference/v4/unified/leads/overview) | | Opportunities | [Opportunities](/api-reference/v4/unified/opportunities/overview) | | Notes | [Notes](/api-reference/v4/unified/notes/overview) | | Tasks | [Tasks](/api-reference/v4/unified/tasks/overview) | Contacts expand into `addresses`, `phone_numbers`, and `external_links` child records via the `expand` query parameter. # BigCommerce Source: https://integrations.docs.commenda.io/ecommerce-integrations/big-commerce Learn more about how to set up our BigCommerce integration. In order to get started using BigCommerce integration, you will need to enter your BigCommerce credentials in the RootFi connect link. The steps to get your BigCommerce credentials are as follows: *** ### Part 1: Register your BigCommerce application 1. Login to your dashboard and go to 'Settings' -> 'API' -> 'Store-level API accounts' ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/bigcommerce/settings.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=6e25b7567af48d5f112ed6ad5771bc5a) 2. Click on '+ Create API account' ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/bigcommerce/create_api_account.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=dd6b329fb4d88439fa94aeec7c5a4bf0) 3. Fill the form data. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/bigcommerce/form_data.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=e6100fbf5e02158e2feda7e83b2f507f) 4. Add required scopes. ![](https://mintcdn.com/rootfi-commenda/Ww3YPpDlQzbumiZY/images/bigcommerce/scopes.png?fit=max\&auto=format\&n=Ww3YPpDlQzbumiZY\&q=85\&s=3ee421c2f782bc6bb1b8b90eea6ff24f) 5. Click on save to view your credentials. ### Part 2: Setting up the integration using Connect by RootFi When your customer is connecting their BigCommerce account to RootFi, they will need to enter their BigCommerce credentials on RootFi's invite link setup. They will need to fill the following information: 1. **Client Id** The client id generated in the above steps. 2. **Client Secret** The client secret generated in the above steps. 3. **Store Hash**: The hash generated in the above steps. 4. **Token** The token generated in the above steps. # E-Commerce Integrations Source: https://integrations.docs.commenda.io/ecommerce-integrations/ecommerce-integrations-overview RootFi' E-Commerce integrations allow you to pull data directly from your customer’s E-Commerce software in real-time. RootFi is a unified API provider designed to streamline e-commerce integrations. By simplifying the process of connecting to various E-Commerce platforms, RootFi helps businesses access and manage their customers e-commerce data with ease. The first step in working with RootFi is to connect an integration - this is the e-commerce platform whose data you want to retrieve and manipulate through RootFi's unified API. ### How do I set up and enable e-commerce integrations? Before you can begin pulling data via RootFi, it is recommended to test the integration by signing up with the e-commerce software provider of your choice, such as Shopify and BigCommerce. Most platforms require OAuth credentials to enable you to connect to their APIs. To get started quickly you can **use RootFi's credentials**, which are provided in the RootFi dashboard. This enables you to enable an integration with a single toggle. When moving to production we recommend you set up your own OAuth credentials. We have compiled detailed information on how to get set up with all the platforms we support. # Shopify Source: https://integrations.docs.commenda.io/ecommerce-integrations/shopify Learn how to set up our Shopify integration. To get started with our Shopify integration, your customer must first create an API Key on their Shopify dashboard. Then, they must enter their Shopify credentials on RootFi when prompted during the onboarding flow via SDK or Invite Link. These steps are elaborated on below. *** ### Part 1: Create a new app on Shopify 1. Login to your Shopify Dashboard. 2. Click ‘Settings‘(Bottom left of the navigation menu) 3. Click ‘Apps and Channels’. (Bottom left of the navigation menu) ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_store_details.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=3987b69c438a28c9040cfa8b79733069) 4. Click ‘Develop apps’ (on the top right) ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_develop_apps.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=502c265c8b637c7a363ffe2124c574c7) 5. Click ‘Create an app’. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_create_app.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=be62f1ab23e79964c60c66c3d9270840) 6. Name the app. We suggest naming it “RootFi integration” or "*Your Company Name* integration". 7. Click ‘Create App.’ ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_confirm_create_app.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=d514134165368e767bcfa435fcedac08) ### Part 2: Generate Shopify API Key 1. Click the ‘Configurations’ tab for the new app created and click ‘Configure’ on the ‘Admin API integration’ card. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_config.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=10428211c6ac5d13f03d65f48bd80fbb) 2. Now, you will have to enable access to needed data models that you want RootFi to sync. We recommend at least giving access to Products, Orders, and Customers. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_oauth_access.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=996705cd3f39c78b1f2f3f72ec798a90) 3. Go to the ‘API Credentials’ tab and click on ‘Install app’ in the ‘Access tokens’ card. This will generate the API Key and Secret Key. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify_api_key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=08efb3ecd1dc796dd7f2417f93e06bbe) 4. Click ‘Reveal token’ and copy the generated API Key. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/shopify/reveal_key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=8120a05d9d1799cd94d9eafe70f8b417) # WooCommerce Source: https://integrations.docs.commenda.io/ecommerce-integrations/woo-commerce Learn more about how to set up our WooCommerce integration. In order to get started using your own credentials for our WooCommerce integration, you will need to first register your Woocommerce application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your WooCommerce application 1. Login to your dashboard and go to 'Settings' and navigate to the 'Advanced' tab. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/woocommerce/advance-tab.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=5ac06c7f124104730f8f564c592715e2) 2. Click on 'Pagesetup' -> 'Rest API' 3. Click add key ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/woocommerce/add-key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=2637987bcc4853266fcc99349b0bc999) 4. Fill up the form. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/woocommerce/generate-key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=c2983adab40be3ef29f0bc871672cbf2) 5. Click on 'Generate API Key' to view your credentials. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/woocommerce/client-id-secret.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=e77f27ab3dbaa59f3741477309496f19) ### Part 2: Setting up the integration Using RootFi Connect When your customer is connecting their WooCommerce account to RootFi, they will need to enter their WooCommerce credentials on RootFi's invite link setup. They will need to fill the following information: 1. **Client Id** The client id generated in the above steps. 2. **Client Secret** The client secret generated in the above steps. 3. **Store Name**: The name of the you store. You can find this in the top right corner of your WooCommerce dashboard. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/woocommerce/storename.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=d11c9da9dc6c79b70c4e4138803d3b8b) # Payment Integrations Source: https://integrations.docs.commenda.io/payment-integrations/payment-integrations-overview RootFi' payment integrations allow you to pull data directly from your customer’s payment software in real-time. RootFi is a unified API provider designed to streamline payment integrations. By simplifying the process of connecting to various payment platforms, RootFi helps businesses access and manage their financial data with ease. The first step in working with RootFi is to connect an integration - this is the payment platform whose data you want to retrieve and manipulate through RootFi's unified API. ### How do I set up and enable Payment Integrations? Before you can begin pulling data via RootFi, it is recommended to test the integration by signing up with the payment software provider of your choice, such as Stripe. Most platforms require OAuth credentials to enable you to connect to their APIs. To get started quickly you can **use RootFi's credentials**, which are provided in the RootFi dashboard. This enables you to enable an integration with a single toggle. When moving to production we recommend you set up your own OAuth credentials. We have compiled detailed information on how to get set up with all the platforms we support. # Stripe Source: https://integrations.docs.commenda.io/payment-integrations/stripe Learn more about how to set up our Stripe integration. In order to get started using your own credentials for our Stripe integration, you will need to first register your Stripe application. After that, you will need to enter your Client ID and Client Secret on the RootFi dashboard. These steps are elaborated upon in detail below. *** ### Part 1: Register your Stripe application 1. Go to the your [Stripe Connect Settings](https://dashboard.stripe.com/settings/connect) from the Stripe dashboard. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/stripe_settings.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=cfa51e47fcdfbc0d14c943c15fd9eaf7) 2. Scroll down to the "Integration" section and enable the "OAuth for Standard Accounts" toggle. 3. Enter \`[ROOTFI CALLBACK URL](/api-reference/v4/overview/environments#callback-url) in the redirect URI as the default. 4. The "Live Mode client ID" will be your **Client ID** that you will enter on RootFi’s dashboard in Part 2 below. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/stripe_oauth.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=c3739b6181009440b2389c392bf50ba8) 5. To generate your Client Secret, go to the [API keys page](https://dashboard.stripe.com/apikeys) in Developers section of the Stripe dashboard and click on the ‘API keys’ tab. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/stripe_api_keys.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=57d958bbf1db0fdc0cf3099a94517dfc) 6. Click "Create secret key" button and a enter a key name to generate a new secret key. This will be your **Client Secret** that you will enter on RootFi’s dashboard in Part 2 below. ![](https://mintcdn.com/rootfi-commenda/w8nR2ntaxiRHlDBi/images/stripe_make_new_key.png?fit=max\&auto=format\&n=w8nR2ntaxiRHlDBi\&q=85\&s=9f8c4af1406c77f8ac362242f08cd0dd) ### Part 2: Enter Your Client ID and Client Secret on the RootFi Dashboard 1. Login to the RootFi dashboard 2. Select the 'Integrations' tab on the sidebar - here you will see a list of platforms you can integrate with 3. Click the 'Set Up' button which is present on the Stripe card. 4. When the form opens up simply enter the 'Client ID' and 'Client Secret' which you generated from the steps above and click 'Save'