---
title: "Read QuickBooks' TrialBalance report as of a date into immutable evidence (#2642)"
method: POST
path: "/accountant/companies/{customerId}/integrations/quickbooks/trial-balances"
tags: ["Accountants"]
---

# Read QuickBooks' TrialBalance report as of a date into immutable evidence (#2642)

`POST /accountant/companies/{customerId}/integrations/quickbooks/trial-balances`

## Request

- Base URL: `https://api.medianfi.com/api/v1`
- URL: `https://api.medianfi.com/api/v1/accountant/companies/{customerId}/integrations/quickbooks/trial-balances`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Calls QuickBooks' TrialBalance report (accrual basis) with `end_date = asOfDate` and stores the payload immutably with its SHA-256. The opening-balance batch needs the snapshot as of the day before the cutoff. Nothing posts.

## Request body

- object
  - `asOfDate` string, date, required

## Response `201`

The stored snapshot

- object
  - `success` true, required
  - `data` QuickBooksTrialBalanceSnapshot, required
    - `id` string, uuid, required
    - `asOfDate` string, date, required
    - `reportBasis` 'Accrual' | 'Cash', required
    - `payloadSha256` string, required
    - `fetchedByUserId` string, uuid, nullable, required
    - `fetchedAt` string, date-time, required
    - `currency` string, required
    - `totalDebitCents` integer, required
    - `totalCreditCents` integer, required
    - `balanced` boolean, required
    - `rows` object[], required
      - `qboAccountId` string, nullable, required
      - `name` string, required
      - `netCents` integer, required: Debit minus credit in integer cents

## Other responses

- `401`: Authentication required
- `403`: Insufficient permissions or not a company member
- `422`: Validation error, QuickBooks not connected, or the report's period, basis or currency does not match
- `503`: QuickBooks is unavailable or returned an unexpected report

---

[API](https://skmtc.dev/medianfi/apis/median-api.md) · [All operations](https://skmtc.dev/medianfi/apis/median-api/llms.txt) · [OpenAPI document](https://skmtc.dev/medianfi/apis/median-api/revisions/20090ea32b0d?raw)
