---
title: "Merge accounting codes"
method: POST
path: "/accounting_codes/{accounting_code}/merge"
tags: ["Accounting Codes"]
---

# Merge accounting codes

`POST /accounting_codes/{accounting_code}/merge`

Merge manual generated accounting codes into other codes. A manual code is any code that has no `xero_id` or `quickbooks_id`, which indicates it was imported from an external accounting platform. The manual codes will be deleted after reassignment, with all references to them updated to the target accounting code.

## Path parameters

- `accounting_code` string, required

## Request body

- object
  - `accounting_code_ids` string[] — An array of one or more accounting code IDs to be removed from the system, with all references to them updated to the accounting code in the resource path. All accounting codes in this array must be of the same `type` as the accounting code in the resource path, and must belong to the same business entity.

## Response `200`

OK

- object
  - `id` string — The unique identifier of the object in Nmbr.
  - `object` string — The type of the object in Nmbr (`"accounting_code"`).
  - `data` AccountingCode
    - `business_entity` object — The Business Entity this accounting code belongs to.
      - `id` string — The unique identifier of the object in Nmbr.
      - `object` string — The type of the object in Nmbr (`"business_entity"`).
    - `type` 'bank' | 'expense' | 'liability' — The type of accounting code.
    - `code` string, nullable — The accounting code identifier as it appears in the chart of accounts.
    - `title` string
    - `title_translations` Translations, nullable
      - `en` string
      - `fr` string
    - `title_translated` string — The translation of the `title` property for the request locale. Computed using the values in `title` and `title_translations` and the value of the request's `Accept-Language` header.
    - `description` string, nullable
    - `description_translations` Translations, nullable
      - `en` string
      - `fr` string
    - `description_translated` string — The translation of the `description` property for the request locale. Computed using the values in `description` and `description_translations` and the value of the request's `Accept-Language` header.
    - `mapping` object, nullable
      - `xero` boolean
      - `quickbooks` boolean
    - `fallback_mappings` object, nullable — Line Item type/subtype pairs that default to this accounting code when no specific mapping is configured. Each entry contains `type` and `subtype`.
    - `created_at` string, dateTime — The date and time the object was created in Nmbr.
    - `updated_at` string, dateTime — The date and time the object was last updated in Nmbr.

---

[API](https://skmtc.net/nmbr/apis/nmbr-api.md) · [All operations](https://skmtc.net/nmbr/apis/nmbr-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/nmbr/nmbr-api/revisions/01cd9c45a923/schema)
