Bank Statement
Extract structured account and transaction data from bank statements, including account details, transactions, and financial summary.
The fields this preset extracts.
accountobjectDetails of the bank account.
holder_namestringFull name of the account holder.
account_number_last_fourstringLast four digits of the account number.
account_typestringType of account.
routing_numberstringBank routing number for the financial institution.
currencystringISO-4217 currency code of the account.
institutionobjectInformation about the financial institution issuing the statement.
namestringOfficial name of the bank or financial institution.
addressstringAddress of the financial institution.
phonestringCustomer service phone number for the institution.
statement_period_startstringFirst date covered by the statement, in ISO-8601 format (YYYY-MM-DD).
statement_period_endstringLast date covered by the statement, in ISO-8601 format (YYYY-MM-DD).
opening_balancenumberAccount balance at the start of the statement period.
closing_balancenumberAccount balance at the end of the statement period.
transactionsarray<object>Chronological list of all transactions posted during the statement period.
summaryobjectAggregated totals and analysis of account activity.
total_depositsnumberSum of all deposit and credit transactions.
total_withdrawalsnumberSum of all debit and withdrawal transactions.
total_feesnumberTotal fees and charges applied during the period.
total_interest_earnednumberTotal interest credited to the account during the period.
curl -X POST 'https://app.staging.xberg.io/v1/extract' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-F 'file=@your-document.pdf' \
--form-string 'options={"preset":"bank_statement"}'- Call mode
- Text and vision
- Citations
- Enabled
- Version
- v1
The instructions Xberg gives the AI model when it extracts this document type.
You are a precise structured-data extractor for bank statements. Extract all account details, transactions, and summary totals exactly as they appear on the document. Do not estimate or infer values. If a field is absent, omit it. Account numbers should only include the last four digits. Dates are ISO-8601 format (YYYY-MM-DD). Transaction amounts are decimals; use negative values for debits and positive values for credits. Transaction types must be one of the specified enum values. Preserve the exact transaction description, merchant name, or reference number as shown. Extract all transactions in their original order. If the document does not match this preset, return {}. Extract only values supported by the document. Omit absent, illegible, or incomplete values, including within nested objects, while retaining other supported values. Do not infer, guess, supply defaults, or calculate missing values. Omit dates whose complete year, month, and day are not explicit. Do not emit null or placeholder strings such as "null" or "2023-XX-XX" for missing values.