> ## Documentation Index
> Fetch the complete documentation index at: https://developers.pleo.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Overview of the legacy Accounts API deprecation. Use it to choose between the Chart of Accounts API (accounts) and the Bookkeeping Categories API (category groups and categories), or both. It links to the guide for each.

The legacy Accounts API has been deprecated. It combined two responsibilities in one API: the accounts of a company and the groups that organise them. Two new APIs replace it. Choose a migration path based on what your integration does.

> **Use this page to answer:**

### Which API replaces the legacy Accounts API?

Two APIs replace it.

* The Chart of Accounts API replaces `/accounts`, for example with `POST /v1/chart-of-accounts`.
* The Bookkeeping Categories API replaces `/account-groups`, for example with `POST /v1/bookkeeping-category-groups`.

If an integration does both, create the accounts first. A category links to an account through its `accountId`. To choose, see the [Legacy Accounts API Overview](https://developers.pleo.io/deprecation/legacy-accounts-api/overview.md).

> This page is the starting point for the legacy Accounts API deprecation. It does not hold the migration steps. Go to the guide that matches the use case:
>
> * [Migrate to the New Chart of Accounts API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-chart-of-accounts-api.md): accounts (`/accounts`).
> * [Migrate to the New Bookkeeping Categories API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-bookkeeping-categories-api.md): category groups and categories (`/account-groups`).

> **Sources for the Chart of Accounts API:**
>
> * OpenAPI reference: the endpoint pages under the [Chart of Accounts API Overview](https://developers.pleo.io/reference/accounts/chart-of-accounts-api-overview.md). Use them for paths, parameters and required fields.
> * How-tos: [How to Sync Accounts](https://developers.pleo.io/docs/current/how-tos/accounting-integrations/imports/accounts/how-to-sync-accounts.md), [How to Create, Update, and Archive Accounts](https://developers.pleo.io/docs/current/how-tos/accounting-integrations/imports/accounts/how-to-create-update-archive-accounts.md), [How to Create Multiple Accounts in a Single Request](https://developers.pleo.io/docs/current/how-tos/accounting-integrations/imports/accounts/how-to-batch-create-accounts.md), [How to Handle a High-Volume Chart of Accounts](https://developers.pleo.io/docs/current/how-tos/accounting-integrations/imports/accounts/how-to-handle-high-volume-accounts.md) and [How to Delete an Account](https://developers.pleo.io/docs/current/how-tos/accounting-integrations/imports/accounts/how-to-delete-accounts.md).
> * If a how-to and the reference disagree, trust the how-to. How-tos record tested behaviour.

> **Sources for the Bookkeeping Categories API:**
>
> * OpenAPI reference: the endpoint pages under the [Bookkeeping Categories API Overview](https://developers.pleo.io/reference/categories/bookkeeping-categories-api-overview.md). This covers categories and category groups. Use them for paths, parameters and required fields.
> * How-tos: none yet.

Terminology: Legacy and New

These guides call the deprecated API the **legacy Accounts API**. They call its replacements the **new Chart of Accounts API** and the **new Bookkeeping Categories API**.

The legacy Accounts API is under `https://openapi.pleo.io/v1/`. The new APIs are under `https://external.pleo.io`.

## Which guide do you need?

| What your integration does | Migrate to |
| :- | :- |
| Syncs the accounts of an Accounting System into Pleo | [New Chart of Accounts API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-chart-of-accounts-api.md) |
| Manages the categories and category groups of a company, and the account that each category uses | [New Bookkeeping Categories API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-bookkeeping-categories-api.md) |
| Does both | Both APIs. Create the accounts first, because a category links to an account by its `accountId`. |

> [card] [Migrate to the New Chart of Accounts API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-chart-of-accounts-api.md)
>
> For integrations that create, read, update, archive or delete the accounts of a company. This is the API that Chart of Accounts Sync uses.

> [card] [Migrate to the New Bookkeeping Categories API](https://developers.pleo.io/deprecation/legacy-accounts-api/migrate-to-bookkeeping-categories-api.md)
>
> For integrations that manage category groups and categories. A category can link to an account and to a Tax Code.

## How the new APIs split the legacy API

| Legacy Accounts API | New API |
| :- | :- |
| Account (`/accounts`) | [Chart of Accounts API](https://developers.pleo.io/reference/accounts/chart-of-accounts-api-overview.md) |
| Account group (`/account-groups`) | [Bookkeeping Categories API](https://developers.pleo.io/reference/categories/bookkeeping-categories-api-overview.md), as a category group |
| The `accountCategoryId` of an account (the ID of its account group) | The `categoryGroupId` of a bookkeeping category. The category links to its account through a separate `accountId` |

If users maintain the categories in the Pleo Web App and you only sync accounts, you need the Chart of Accounts API only. For how the sync works, see the [Chart of Accounts Sync Overview](https://developers.pleo.io/docs/current/platform/accounting-integrations/imports/accounts/accounts-sync-overview.md).
