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

# get_statement

Get the full, audit-grade detail of one statement you can access.

Use this to audit a single statement end-to-end — drill into the summary rows
`list_statements` returns. It returns one minimal row per commission line
(drill into a line's variables and scopes with `get_statement_compensation`),
the complete activity log, the validation state, the draw balance, and the
linked requests.

Identify the statement one of two ways (exactly one): `statement_id` (the id
`list_statements` returns), or `owner` + `period` (the statement's user
and its month).

The headline `total_payment` is converted into the currency named by
`currency_mode` (payment by default) and labelled with it, so amount and
currency always agree. The per-line compensation breakdown stays in the plan's
calculation currency.

A statement you can't access reads exactly like one that doesn't exist, so the
error never reveals a statement outside your scope.

## Parameters

<Accordion title="Body" defaultOpen>
  <ParamField body="statement_id" type="string">
    The statement's id, as returned by list\_statements. Mutually exclusive with
    owner / period.
  </ParamField>

  <ParamField body="owner" type="string">
    The statement's user, matched by name or email (case-insensitive substring)
    or by ObjectId — same matching as list\_users. Must be paired with period.
  </ParamField>

  <ParamField body="period" type="string">
    The statement's period in YYYY-MM format (e.g. 2026-03, never day-first).
    Must be paired with owner.
  </ParamField>

  <ParamField body="currency_mode" type="string">
    Which currency total\_payment is converted into and labelled with: 'payment'
    (default) — the currency the user is paid in; 'calculation' — the currency
    the plan computes in; 'company' — the company's global currency. The amount
    and its currency always agree. One of: `company`, `payment`, `calculation`.
  </ParamField>
</Accordion>

## Response

<Accordion title="Body" defaultOpen>
  <ResponseField name="id" type="string" />

  <ResponseField name="resource_url" type="string">
    Deep link to open this statement in the Qobra web app.
  </ResponseField>

  <ResponseField name="user_email" type="string" />

  <ResponseField name="period" type="string" />

  <ResponseField name="status" type="string">
    Overall processing state: error (calculation failed), ongoing (open, not yet
    locked), locked (frozen, not yet paid), paid (sent to payroll). A paid
    statement is always frozen too. Distinct from the per-period reporting stage
    of list\_statement\_periods. One of: `error`, `ongoing`, `locked`, `paid`.
  </ResponseField>

  <ResponseField name="total_payment" type="number">
    Net amount to be paid out on this statement, expressed in `currency` —
    already reflects draw and manual payments, so it is not just the sum of the
    compensation lines.
  </ResponseField>

  <ResponseField name="currency" type="string">
    The ISO currency code that total\_payment is expressed in. One of: `AED`,
    `AFN`, `ALL`, `AMD`, `ANG`, `AOA`, `ARS`, `AUD`, `AWG`, `AZN`, `BAM`, `BBD`,
    `BDT`, `BGN`, `BHD`, `BIF`, `BMD`, `BND`, `BOB`, `BOV`, `BRL`, `BSD`, `BTN`,
    `BWP`, `BYR`, `BZD`, `CAD`, `CDF`, `CHF`, `CLF`, `CLP`, `CNY`, `COP`, `COU`,
    `CRC`, `CUC`, `CUP`, `CVE`, `CZK`, `DJF`, `DKK`, `DOP`, `DZD`, `EGP`, `ERN`,
    `ETB`, `EUR`, `FJD`, `FKP`, `GBP`, `GEL`, `GHS`, `GIP`, `GMD`, `GNF`, `GTQ`,
    `GYD`, `HKD`, `HNL`, `HRK`, `HTG`, `HUF`, `IDR`, `ILS`, `INR`, `IQD`, `IRR`,
    `ISK`, `JMD`, `JOD`, `JPY`, `KES`, `KGS`, `KHR`, `KMF`, `KPW`, `KRW`, `KWD`,
    `KYD`, `KZT`, `LAK`, `LBP`, `LKR`, `LRD`, `LSL`, `LTL`, `LVL`, `LYD`, `MAD`,
    `MDL`, `MGA`, `MKD`, `MMK`, `MNT`, `MOP`, `MRO`, `MUR`, `MVR`, `MWK`, `MXN`,
    `MYR`, `MZN`, `NAD`, `NGN`, `NIO`, `NOK`, `NPR`, `NZD`, `OMR`, `PAB`, `PEN`,
    `PGK`, `PHP`, `PKR`, `PLN`, `PYG`, `QAR`, `RMB`, `RON`, `RSD`, `RUB`, `RWF`,
    `SAR`, `SBD`, `SCR`, `SDG`, `SEK`, `SGD`, `SHP`, `SLL`, `SOS`, `SRD`, `STD`,
    `SVC`, `SYP`, `SZL`, `THB`, `TJS`, `TMT`, `TND`, `TOP`, `TRY`, `TTD`, `TWD`,
    `TZS`, `UAH`, `UGX`, `USD`, `UYI`, `UYU`, `UZS`, `VEF`, `VND`, `VUV`, `WON`,
    `WST`, `XAF`, `XAG`, `XAU`, `XCD`, `XOF`, `XPD`, `XPF`, `XPT`, `XSU`, `YER`,
    `ZAR`, `ZMK`, `ZWL`.
  </ResponseField>

  <ResponseField name="last_ready_at" type="string">
    When the statement last finished computing and was up to date; null if it
    never reached that state.
  </ResponseField>

  <ResponseField name="linked_requests" type="object[]">
    <Expandable title="object properties">
      <ResponseField name="id" type="string" />

      <ResponseField name="reference" type="string" />

      <ResponseField name="name" type="string" />

      <ResponseField name="creator_email" type="string" />

      <ResponseField name="assignee_email" type="string" />
    </Expandable>
  </ResponseField>

  <ResponseField name="overwritten" type="boolean">
    True if at least one amount was manually adjusted.
  </ResponseField>

  <ResponseField name="last_calculating_at" type="string" />

  <ResponseField name="groups" type="object[]">
    The groups (by dimension) this user belongs to on the statement.

    <Expandable title="object properties">
      <ResponseField name="id" type="string" />

      <ResponseField name="resource_url" type="string">
        Deep link to open this group in the Qobra web app.
      </ResponseField>

      <ResponseField name="name" type="string" />

      <ResponseField name="key" type="string">
        The group's stable key — the identifier used to match it when synced
        from an integration, distinct from its display name.
      </ResponseField>

      <ResponseField name="dimension" type="string">
        Name of the dimension the group belongs to (the kind of grouping, e.g.
        'Country' or 'Team'). Null if the dimension is unknown.
      </ResponseField>

      <ResponseField name="archived" type="boolean" />

      <ResponseField name="member_count" type="integer">
        Number of users currently in the group (attributions active as of
        today). Past and future members are excluded.
      </ResponseField>
    </Expandable>
  </ResponseField>

  <ResponseField name="balance" type="object">
    <Expandable title="object properties">
      <ResponseField name="balance" type="number">
        Opening balance carried over from the previous period.
      </ResponseField>

      <ResponseField name="balance_override" type="number">
        Balance set manually (overwrite); null if not overridden.
      </ResponseField>

      <ResponseField name="drawn_value" type="number">
        The draw applied this period.
      </ResponseField>

      <ResponseField name="manual" type="boolean">
        True when the balance was entered or edited by hand.
      </ResponseField>

      <ResponseField name="balance_after_draw" type="number">
        Balance once this period's draw is applied.
      </ResponseField>
    </Expandable>
  </ResponseField>

  <ResponseField name="validations" type="object[]">
    <Expandable title="object properties">
      <ResponseField name="user_email" type="string" />

      <ResponseField name="status" type="string">
        Workflow step this event records: freeze (statement locked), validation
        (an intermediate, informational sign-off), payment (sent to payroll).
        One of: `freeze`, `validation`, `payment`.
      </ResponseField>

      <ResponseField name="date" type="string" />
    </Expandable>
  </ResponseField>

  <ResponseField name="compensations" type="object[]">
    One minimal row per commission line. Drill into a line with
    get\_statement\_compensation for its variables and scopes.

    <Expandable title="object properties">
      <ResponseField name="compensation_id" type="string">
        Identifier to pass to get\_statement\_compensation for the full breakdown
        (variables, scopes). Null for a manual payment or draw that has no
        underlying compensation.
      </ResponseField>

      <ResponseField name="name" type="string" />

      <ResponseField name="plan_name" type="string" />

      <ResponseField name="value" type="number" />

      <ResponseField name="currency" type="string">
        One of: `AED`, `AFN`, `ALL`, `AMD`, `ANG`, `AOA`, `ARS`, `AUD`, `AWG`,
        `AZN`, `BAM`, `BBD`, `BDT`, `BGN`, `BHD`, `BIF`, `BMD`, `BND`, `BOB`,
        `BOV`, `BRL`, `BSD`, `BTN`, `BWP`, `BYR`, `BZD`, `CAD`, `CDF`, `CHF`,
        `CLF`, `CLP`, `CNY`, `COP`, `COU`, `CRC`, `CUC`, `CUP`, `CVE`, `CZK`,
        `DJF`, `DKK`, `DOP`, `DZD`, `EGP`, `ERN`, `ETB`, `EUR`, `FJD`, `FKP`,
        `GBP`, `GEL`, `GHS`, `GIP`, `GMD`, `GNF`, `GTQ`, `GYD`, `HKD`, `HNL`,
        `HRK`, `HTG`, `HUF`, `IDR`, `ILS`, `INR`, `IQD`, `IRR`, `ISK`, `JMD`,
        `JOD`, `JPY`, `KES`, `KGS`, `KHR`, `KMF`, `KPW`, `KRW`, `KWD`, `KYD`,
        `KZT`, `LAK`, `LBP`, `LKR`, `LRD`, `LSL`, `LTL`, `LVL`, `LYD`, `MAD`,
        `MDL`, `MGA`, `MKD`, `MMK`, `MNT`, `MOP`, `MRO`, `MUR`, `MVR`, `MWK`,
        `MXN`, `MYR`, `MZN`, `NAD`, `NGN`, `NIO`, `NOK`, `NPR`, `NZD`, `OMR`,
        `PAB`, `PEN`, `PGK`, `PHP`, `PKR`, `PLN`, `PYG`, `QAR`, `RMB`, `RON`,
        `RSD`, `RUB`, `RWF`, `SAR`, `SBD`, `SCR`, `SDG`, `SEK`, `SGD`, `SHP`,
        `SLL`, `SOS`, `SRD`, `STD`, `SVC`, `SYP`, `SZL`, `THB`, `TJS`, `TMT`,
        `TND`, `TOP`, `TRY`, `TTD`, `TWD`, `TZS`, `UAH`, `UGX`, `USD`, `UYI`,
        `UYU`, `UZS`, `VEF`, `VND`, `VUV`, `WON`, `WST`, `XAF`, `XAG`, `XAU`,
        `XCD`, `XOF`, `XPD`, `XPF`, `XPT`, `XSU`, `YER`, `ZAR`, `ZMK`, `ZWL`.
      </ResponseField>

      <ResponseField name="overwritten" type="boolean" />

      <ResponseField name="error" type="boolean" />

      <ResponseField name="validated" type="boolean" />

      <ResponseField name="manual" type="boolean" />

      <ResponseField name="draw" type="boolean" />

      <ResponseField name="effective_non_financial_reward" type="string" />
    </Expandable>
  </ResponseField>

  <ResponseField name="activities" type="object[]">
    <Expandable title="object properties">
      <ResponseField name="actor_email" type="string" />

      <ResponseField name="description" type="string" />

      <ResponseField name="date" type="string" />

      <ResponseField name="comment" type="string" />

      <ResponseField name="reason" type="string" />

      <ResponseField name="modifications" type="object[]">
        <Expandable title="object properties">
          <ResponseField name="field" type="string" />

          <ResponseField name="before" type="any" />

          <ResponseField name="after" type="any" />

          <ResponseField name="before_currency" type="string">
            One of: `AED`, `AFN`, `ALL`, `AMD`, `ANG`, `AOA`, `ARS`, `AUD`,
            `AWG`, `AZN`, `BAM`, `BBD`, `BDT`, `BGN`, `BHD`, `BIF`, `BMD`,
            `BND`, `BOB`, `BOV`, `BRL`, `BSD`, `BTN`, `BWP`, `BYR`, `BZD`,
            `CAD`, `CDF`, `CHF`, `CLF`, `CLP`, `CNY`, `COP`, `COU`, `CRC`,
            `CUC`, `CUP`, `CVE`, `CZK`, `DJF`, `DKK`, `DOP`, `DZD`, `EGP`,
            `ERN`, `ETB`, `EUR`, `FJD`, `FKP`, `GBP`, `GEL`, `GHS`, `GIP`,
            `GMD`, `GNF`, `GTQ`, `GYD`, `HKD`, `HNL`, `HRK`, `HTG`, `HUF`,
            `IDR`, `ILS`, `INR`, `IQD`, `IRR`, `ISK`, `JMD`, `JOD`, `JPY`,
            `KES`, `KGS`, `KHR`, `KMF`, `KPW`, `KRW`, `KWD`, `KYD`, `KZT`,
            `LAK`, `LBP`, `LKR`, `LRD`, `LSL`, `LTL`, `LVL`, `LYD`, `MAD`,
            `MDL`, `MGA`, `MKD`, `MMK`, `MNT`, `MOP`, `MRO`, `MUR`, `MVR`,
            `MWK`, `MXN`, `MYR`, `MZN`, `NAD`, `NGN`, `NIO`, `NOK`, `NPR`,
            `NZD`, `OMR`, `PAB`, `PEN`, `PGK`, `PHP`, `PKR`, `PLN`, `PYG`,
            `QAR`, `RMB`, `RON`, `RSD`, `RUB`, `RWF`, `SAR`, `SBD`, `SCR`,
            `SDG`, `SEK`, `SGD`, `SHP`, `SLL`, `SOS`, `SRD`, `STD`, `SVC`,
            `SYP`, `SZL`, `THB`, `TJS`, `TMT`, `TND`, `TOP`, `TRY`, `TTD`,
            `TWD`, `TZS`, `UAH`, `UGX`, `USD`, `UYI`, `UYU`, `UZS`, `VEF`,
            `VND`, `VUV`, `WON`, `WST`, `XAF`, `XAG`, `XAU`, `XCD`, `XOF`,
            `XPD`, `XPF`, `XPT`, `XSU`, `YER`, `ZAR`, `ZMK`, `ZWL`.
          </ResponseField>

          <ResponseField name="after_currency" type="string">
            One of: `AED`, `AFN`, `ALL`, `AMD`, `ANG`, `AOA`, `ARS`, `AUD`,
            `AWG`, `AZN`, `BAM`, `BBD`, `BDT`, `BGN`, `BHD`, `BIF`, `BMD`,
            `BND`, `BOB`, `BOV`, `BRL`, `BSD`, `BTN`, `BWP`, `BYR`, `BZD`,
            `CAD`, `CDF`, `CHF`, `CLF`, `CLP`, `CNY`, `COP`, `COU`, `CRC`,
            `CUC`, `CUP`, `CVE`, `CZK`, `DJF`, `DKK`, `DOP`, `DZD`, `EGP`,
            `ERN`, `ETB`, `EUR`, `FJD`, `FKP`, `GBP`, `GEL`, `GHS`, `GIP`,
            `GMD`, `GNF`, `GTQ`, `GYD`, `HKD`, `HNL`, `HRK`, `HTG`, `HUF`,
            `IDR`, `ILS`, `INR`, `IQD`, `IRR`, `ISK`, `JMD`, `JOD`, `JPY`,
            `KES`, `KGS`, `KHR`, `KMF`, `KPW`, `KRW`, `KWD`, `KYD`, `KZT`,
            `LAK`, `LBP`, `LKR`, `LRD`, `LSL`, `LTL`, `LVL`, `LYD`, `MAD`,
            `MDL`, `MGA`, `MKD`, `MMK`, `MNT`, `MOP`, `MRO`, `MUR`, `MVR`,
            `MWK`, `MXN`, `MYR`, `MZN`, `NAD`, `NGN`, `NIO`, `NOK`, `NPR`,
            `NZD`, `OMR`, `PAB`, `PEN`, `PGK`, `PHP`, `PKR`, `PLN`, `PYG`,
            `QAR`, `RMB`, `RON`, `RSD`, `RUB`, `RWF`, `SAR`, `SBD`, `SCR`,
            `SDG`, `SEK`, `SGD`, `SHP`, `SLL`, `SOS`, `SRD`, `STD`, `SVC`,
            `SYP`, `SZL`, `THB`, `TJS`, `TMT`, `TND`, `TOP`, `TRY`, `TTD`,
            `TWD`, `TZS`, `UAH`, `UGX`, `USD`, `UYI`, `UYU`, `UZS`, `VEF`,
            `VND`, `VUV`, `WON`, `WST`, `XAF`, `XAG`, `XAU`, `XCD`, `XOF`,
            `XPD`, `XPF`, `XPT`, `XSU`, `YER`, `ZAR`, `ZMK`, `ZWL`.
          </ResponseField>
        </Expandable>
      </ResponseField>
    </Expandable>
  </ResponseField>

  <ResponseField name="errors" type="object[]">
    The statement's detailed calculation errors, resolved to variable / quota /
    scope names. Populated only for callers who can manage compensations or
    quotas (mirroring the web app's admin-only error panel); empty for anyone
    else and whenever the statement has no calculation error.

    <Expandable title="object properties">
      <ResponseField name="compensation_name" type="string" />

      <ResponseField name="plan_name" type="string" />

      <ResponseField name="variable_name" type="string">
        The variable whose computation errored.
      </ResponseField>

      <ResponseField name="scope_name" type="string">
        The scope the errored variable belongs to, when the error is on a scope
        record rather than a compensation variable.
      </ResponseField>

      <ResponseField name="error_type" type="string">
        The kind of calculation error:

        * FormulaError / DivisionZeroError: the variable's formula could not be
          computed.

        * TypeError: a value had an unexpected type.

        * ConversionError: no exchange rate is configured for a currency in the
          period.

        * NullQuotaError / NullQuotaProjectionError: a quota has no value for
          the period.

        * ScopeTooLargeError: a scope returned too many records to compute.

        * FieldDependencyError / FieldReferenceError / DependencyError: the
          variable depends on another field/variable that is missing or itself
          in error. One of: `FormulaError`, `DivisionZeroError`, `TypeError`,
          `ConversionError`, `NullQuotaError`, `NullQuotaProjectionError`,
          `ScopeTooLargeError`, `FieldDependencyError`, `FieldReferenceError`,
          `DependencyError`.
      </ResponseField>

      <ResponseField name="detail" type="string">
        A human-readable specifics line for the error — the missing currency,
        quota, scope or dependency by name — or null when the error type carries
        no extra detail.
      </ResponseField>
    </Expandable>
  </ResponseField>
</Accordion>
