Welcome to Codat's API Documentation

Develop against the Codat API.

Guides    API Explorer

Configuration

The Commerce module configuration is used to set up options for how a linked commerce data source should be synchronised with a linked accounting software instance for a company.

Open in Commerce API Explorer

Usage

The configuration endpoint should be used to set up the following options for data synchronisation. In most instances the endpoint will be used to power an end-user facing UX for merchants to select these options themselves.

Enabled / Disabled

The synchronisation can be enabled or disabled at the root level or at the individual data type level: sales, payments and fees (see Overview for description).

Schedule

The schedule config section specifies when the synchronisation will push new data to the connected accounting software. It is not used to determine the split of commerce data by time period when inserted into the accounting software; for information on this, please see grouping (below).

Accounts

Payments, transactions, invoices, line items etc. must all be synchronised with the correct linked account from the business' chart of accounts to ensure correctness and consistency of the user's accounting software data. For each account configuration the user can set up, the config data model provides:

  1. Metadata for the account configuration, including if it is required, labelText and descriptionText. This information is often used to dynamically build front-end UX for the end-user.

  2. A list of valid accounts that already exist in the user's accounting software, the accountOptions. The chosen account from this list will have the id set as the selectedAccountId field.

  3. New accounts can be created using the New Account Endpoints.

Grouping

To ensure data is synchronised with the level of detail required by the user, the grouping configuration must be set.

The grouping config covers the following options:

What to group by

The split of transaction data synchronised to a user's accounting software is determined by the selectedGrouping. The greater the number of selected groups, the more granular the data synchronised to accounting software will be.

Period

The groupingPeriod defines how transactions should be grouped by time period.

Tax Rates

Goods and services sold by companies may have different tax rates, requiring that synchronised sales transaction data is grouped by tax rate. A valid tax rate in the destination accounting package needs to be selected for each of the tax rates which will be used during the synchronisation process.

Updated 2 months ago

Configuration


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.