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

# Add Chart Accounts API

> Add one or more GL accounts to a Breezing company's chart of accounts through the API, with no accounting integration needed.



## OpenAPI

````yaml POST /accounts
openapi: 3.1.0
info:
  title: Breezing Public API
  version: 1.0.0
  description: >-
    Crypto accounting API for programmatic access and AI agents. Authenticate
    with an API key using the Authorization header: `Bearer brz_...`
servers:
  - url: https://api.breezing.io/v1
security:
  - BearerAuth: []
paths:
  /accounts:
    post:
      tags:
        - Chart of Accounts
      summary: Add accounts to the chart
      description: >-
        Append one or more GL accounts to the company's chart of accounts, with
        no accounting integration involved (the dashboard's "Add account" flow).
        Codes are unique per company case-insensitively: a code already in the
        chart answers 409 and NOTHING from the request is added, so fix the
        request and resend it whole. A whole chart can be loaded this way in
        batches. The request lands as one Chart Version in the chart history
        (source "Public API"). Requires write access.
      parameters:
        - schema:
            type: string
            description: >-
              Organization ID. Use GET /v1/companies to discover available
              org/company pairs.
            example: '1'
          required: true
          description: >-
            Organization ID. Use GET /v1/companies to discover available
            org/company pairs.
          name: orgId
          in: query
        - schema:
            type: string
            description: >-
              Company ID. Use GET /v1/companies to discover available companies
              and their access levels.
            example: '1'
          required: true
          description: >-
            Company ID. Use GET /v1/companies to discover available companies
            and their access levels.
          name: companyId
          in: query
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AddChartAccountsBody'
      responses:
        '200':
          description: Accounts added
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - true
                  data:
                    type: object
                    properties:
                      added:
                        type: array
                        items:
                          $ref: '#/components/schemas/AccountingAccount'
                        description: >-
                          The added accounts with their effective
                          classification.
                      total:
                        type: integer
                        description: Accounts in the chart after the add.
                    required:
                      - added
                      - total
                required:
                  - success
                  - data
        '400':
          description: >-
            Bad request: a code or name is missing, a code repeats inside the
            request, or a classification is unknown
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '401':
          description: Invalid or missing API key
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '403':
          description: >-
            API key has no access to this company, has read-only access where
            write was required, or the company subscription is inactive
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '409':
          description: An account code is already in the chart
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
      security:
        - BearerAuth: []
components:
  schemas:
    AddChartAccountsBody:
      type: object
      properties:
        accounts:
          type: array
          items:
            $ref: '#/components/schemas/ChartAccountInput'
          minItems: 1
          maxItems: 500
          description: >-
            The accounts to add (1-500 per request). Every code must be new to
            the chart.
      required:
        - accounts
    AccountingAccount:
      type: object
      properties:
        code:
          type: string
          nullable: true
          description: >-
            Account code/identifier. Use this exact value when setting
            `account`, `assetAccount`, or `feeAssetAccount` on a transaction or
            asset.
        name:
          type: string
          nullable: true
          description: Display name of the account.
        type:
          type: string
          description: >-
            Account type as reported by the accounting platform (e.g. "Bank",
            "Other Current Asset", "EXPENSE").
        classification:
          type: string
          nullable: true
          enum:
            - bank
            - currentAsset
            - fixedAsset
            - nonCurrentAsset
            - currentLiability
            - nonCurrentLiability
            - equity
            - revenue
            - otherIncome
            - costOfSales
            - expense
            - otherExpense
            - null
          description: >-
            Breezing statement classification derived from the account type
            (bank, currentAsset, fixedAsset, nonCurrentAsset, currentLiability,
            nonCurrentLiability, equity, revenue, otherIncome, costOfSales,
            expense, otherExpense), or null when the type could not be
            classified. Decides where the account lands on the Profit and Loss
            and Balance Sheet; editable per account on the Chart of Accounts
            page.
      required:
        - code
        - name
        - type
        - classification
    ChartAccountInput:
      type: object
      properties:
        code:
          type: string
          minLength: 1
          maxLength: 64
          description: >-
            The account code. It is the identity transactions, assets, rules and
            mappings reference by value, so it cannot change later. Unique per
            company, case-insensitively.
          example: '6200'
        name:
          type: string
          minLength: 1
          maxLength: 200
          description: Display name.
          example: Cloud Hosting
        type:
          type: string
          maxLength: 64
          description: >-
            Free-text account type. Provider-style labels (Xero "EXPENSE",
            QuickBooks "Other Current Asset", Bexio "1") and plain words
            ("Bank", "Revenue") drive the automatic classification.
          example: EXPENSE
        classification:
          type: string
          nullable: true
          maxLength: 40
          description: >-
            Statement classification override: one of the twelve keys (bank,
            currentAsset, fixedAsset, nonCurrentAsset, currentLiability,
            nonCurrentLiability, equity, revenue, otherIncome, costOfSales,
            expense, otherExpense) or its label ("Current Asset"). Omit for
            automatic derivation from `type`. On PATCH, null clears a stored
            override.
      required:
        - code
        - name

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.