Bank Statement OCR
Reads a Thai bank statement and returns the account details and the whole transaction table.
/ocr/v3/bank-statement/fileTry it- Price1 ICper page
- Measured99.7%
- Served29.1Kcalls
Input

OutputPOST /ocr/v3/bank-statement/file
- bank_name
- ธนาคารกสิกรไทย
- account_holder_name
- น.ส. สมหญิง ตัวอย่าง
- account_number
- XXX-2-48512-X
- account_type
- เงินฝากออมทรัพย์
- branch
- สาขาซีคอนสแควร์ 2
- period_from
- 01-04-2018
- period_to
- 20-09-2018
- total_withdrawal_amount
- 101797.39
- total_deposit_amount
- 101780.19
- transactions
- date: 10-09-2018 description: ฝากเงินสด ไม่มีสมุดคู่ฝาก withdrawal: — deposit: 100 balance: 206.14 channel: 0929
Request
multipart/form-data only; there is no Base64 form. Every page of a PDF is read and billed.
Headers
apikeystringrequiredBody
filefilerequiredreturn_ocrbooleantrue to include the raw OCR text.target_langstringth, the default, en, or auto to keep the document's own language.include_confidencebooleantrue: a confidence from 0.00 to 1.00 per field./v3/store/ocr/bank-statement is the same endpoint under the store prefix.
Response
The iapp-input-pages header carries the number of pages billed.
docsarrayOne entry per document read
docs.processedobjectThe fields read from the document
docs.processed.bank_namestringdocs.processed.account_holder_namestringdocs.processed.account_numberstringdocs.processed.account_typestringdocs.processed.branchstringdocs.processed.period_fromdocs.processed.period_todocs.processed.total_withdrawal_amountdocs.processed.total_deposit_amountdocs.processed.transactionsarrayOne row per transaction
docs.processed.transactions.datestringdocs.processed.transactions.descriptionstringdocs.processed.transactions.withdrawaldocs.processed.transactions.depositnumberdocs.processed.transactions.balancenumberdocs.processed.transactions.channelstringdocs.messagestringdocs.rawobjectdocs.confidenceobjectdocs.process_msintegerdocs_countintegerprocess_msintegerStatus codes
| Code | Meaning |
|---|---|
| 400 | Unsupported file extension, or a file over 50 MB |
| 404 | Unknown document type in the URL |
| 422 | No file attached |
| 500 | Processing error; the response carries a code to quote to support |
| 502 | Temporary processing failure, also when any page of a multi-page file fails (code: PROCESSING_FAILED). Not charged; retry |
| 503 | Service busy (PROCESSING_BUSY). Not charged; retry, after the seconds in Retry-After when that header is present |
| 504 | Processing timed out (PROCESSING_TIMEOUT). Not charged; retry |
Details
Measured
On the production service, 28 October 2026, against 40 synthetic Thai bank statements: every value and bank name invented, every page watermarked "specimen", half degraded as office scans and half as phone photographs.
| Measure | Result |
|---|---|
| Account and summary fields exactly right, 360 fields | 99.7% (95% CI 99.2–100.0) |
| Scan / phone photograph | 100.0% / 99.4% |
| Statements with every account and summary field right | 97.5% |
| Transaction rows: date, withdrawal, deposit, balance (1,530 values) | 100.0% |
| Weakest field: account number | 97.5% |
| All 11 business-document types in the benchmark, 5,092 fields | 97.9% |
| Median time per page through the API, 44 documents across the 11 types | 10.8 s (19.9 s at the 95th percentile) |
Statements with long transaction tables take the longest to process. Real statements, with stamps, handwriting and layouts that differ by bank, score lower than this synthetic set. Method and every field: the benchmark (PDF).
Limits
- Only the fields above are extracted.
- Degraded scans, glare and handwriting over printed values lower accuracy. Prefer the original PDF, a square-on photograph in even light, or a scan at 300 dpi or more.
- The per-field confidence does not mark errors: across the 11 document types in the benchmark it averaged 0.957 on wrong fields and 0.967 on right ones, and 97.4% of wrong fields scored 0.90 or more. Choose fields for review with arithmetic checks (totals, VAT, balances) and identifier check digits instead.
Data handling
Consent and notice under PDPA and GDPR remain with you as the data controller.