Accountant Portal
Journal Entries

Record a prior-period correction against opening equity

Changed on

#3887. The one path that may post to 3200 Retained Earnings, which every other journal path refuses (422). The entry is dated on the first day of a fiscal year (YYYY-01-01, opening equity; statements are calendar-year), carries a required reason, and is balanced. Every 3200 line needs a counter-line on the other side on another balance-sheet account that is not Opening Balance Equity; lines carry no transaction or document. Period and filing locks and every other account block still apply. The entry, its gl_adjustments link (kind prior_period_adjustment) and its audit row (with the reason) are written in one transaction. With an Idempotency-Key header or idempotencyKey field, a retry of the same request returns the entry already posted; the same key with a different payload is refused with 409. The cash flow statement presents the entry as a restatement of opening balances, never as an activity: in a window that opens on its date its cash leg is part of beginning cash; in a window that crosses its date its cash leg is the financing line "Prior period adjustment (restatement of opening balances)". Assigned accountants; the service principal as a high-impact operation. The optional openingCorrection records a pre-2026 discrepancy posted on January 1, 2026. A signed-in accountant supplies its support for the posting entity: a document (supportDocumentId) or, from migration 778, staff-only evidence (staffEvidenceId), exactly one. The destination period must be open. The posting must leave protected years and filing-locked periods intact.

post/accountant/companies/{customerId}/journal-entries/prior-period-adjustments

Request

  • Base URL
    https://api.medianfi.com/api/v1
  • Auth
    • HTTP bearer
    • or API key in header X-API-Key

Path parameters

customerId, string uuid required

Headers

Idempotency-Key, string

Client retry key (at most 200 characters); the body's idempotencyKey wins when both are sent.

Request body

CreatePriorPeriodAdjustmentInput required
entityId, string uuid

Concrete legal posting entity; defaults to the company's primary entity.

currency, string required
entryDate, string date required

The first day of a fiscal year (YYYY-01-01).

description, string required
reason, string required

Why the prior-period figures were wrong; stored on the adjustment link and the audit row.

idempotencyKey, string

Client retry key; a retry with the same key and payload returns the entry already posted.

openingCorrection, object

Evidence for an opening correction submitted by a signed-in accountant. Exactly one of supportDocumentId or staffEvidenceId (migration 778).

lines, object[] required

Example request

{
  "currency": "USD",
  "entryDate": "2026-01-01",
  "openingCorrection": {
    "sourceDate": "2025-12-31"
  }
}

Response

Prior-period adjustment posted and linked

PriorPeriodAdjustmentResponse required
success, boolean
data, object

Changes

    • info

      added the new optional request property openingCorrection/staffEvidenceId

    • info

      the request property openingCorrection/supportDocumentId became optional

    • info

      added the new optional request property openingCorrection