Accountant Portal

Change only the code and/or name of an existing GL account, keeping its id (#2883)

The identity-preserving chart edit. It writes ONLY code, name and updated_at on the account, so the id is unchanged and every journal line, bank or integration mapping, QuickBooks account mapping, role and schedule stays attached. It cannot change type, subtype, detail type, report section, description, parent, normal balance, isActive, isLocked, isPostable, provenance or any classification: any other body key is a 422, never an ignored field. It has no posting cutoff, automatic mapping, automatic sync or QuickBooks write side effect, and it creates, deactivates and retires nothing. expected is the code and name the caller last read; the edit lands only on exactly that row. A request whose target code and name are already on the account replays: 200 with meta.replayed: true, no write and no audit record. A successful edit writes one audit record (action update, entity gl_account, lifecycleAction: identity_edit) with the reason, the before and after snapshot, the acting user and, for the service token, its API key id. The edit and its audit record commit in one database transaction: neither lands without the other, so a 500 or 503 means nothing was written and the request can be retried unchanged. A feed-created bank or card account (source: integration) is relabelled like any other, since its feed links by id. Conflicts are reported, never resolved: a code held by another account (active, inactive or retired), an active name held by another active account, a company merchant rule that targets the code being left or taken, or a live QuickBooks create-account write-back item for the account return 409 GL_ACCOUNT_IDENTITY_CONFLICT with every conflict in error.extensions.conflicts. Nothing is overwritten, swapped, deactivated or retired to make room. Service-principal access reviewed 2026-10-02 (#2883); the full PATCH .../chart-of-accounts/{accountId} stays bearer-only.

post/accountant/companies/{customerId}/chart-of-accounts/{accountId}/identity

Request

  • Base URL: https://api.medianfi.com/api/v1
  • URL: https://api.medianfi.com/api/v1/accountant/companies/{customerId}/chart-of-accounts/{accountId}/identity
  • Auth: one of:
    • HTTP bearer
    • API key in header X-API-Key

Request body

codestring

The new code. 1-7 letters, digits, dots or dashes, so it survives as a QuickBooks account number.

namestring

The new name. Single line, no HTML, no colon or double quote, not an account code (3-6 digits), no repeated spaces.

reasonstring required

Why the account is being recoded or renamed; stored on the audit record.

Response

The account after the edit, or the unchanged account when the request replays

successtrue required

Example response

{
  "data": {
    "code": "1000",
    "name": "Cash"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.