Extract transactions from an uploaded bank-statement PDF
Upload a bank-statement PDF and get back the OCR-extracted transactions — the same engine behind the LedgerSync app’s Bank Statement Converter.
Unlike the other statement endpoints, this call is
customer-level: no client_id is required, and the upload is
standalone — it never attaches to a connection, account, or
stored statement.
Constraints: the file must be a PDF (%PDF- header) of at most
30 MB — larger uploads are rejected with 413, and requests
over 32 MB may be cut at our edge with a non-JSON 413. Requires
the write:statements scope. Concurrency and daily budgets
apply per customer beyond the standard request-rate tiers
(each extraction runs a real OCR pass); exceeding them returns
429 rate_limit_exceeded.
This one’s genuinely async: you get a 202 with an
operation_id. Poll GET /operations/{operation_id}
— a typical statement completes in well under a minute. On
success the operation’s result carries
kind: statement_extraction with the extracted transactions;
output is JSON only (no CSV/XLSX export). There is no webhook
for this operation type today — polling is the only completion
signal.
Authorizations
Pass your secret key in the Authorization header as a Bearer
token: Authorization: Bearer sk_test_... (sandbox) or
Bearer sk_live_... (production).
Keys are created in the developer portal and the plaintext secret is shown exactly once at creation. Treat them like passwords — never embed them in mobile apps or front-end code.
Body
The bank-statement PDF. Max 30 MB.
Response
The request was accepted but the underlying work runs
asynchronously. Use the returned operation_id to poll
GET /operations/{operation_id} or just wait for the matching
webhook event.
Returned with 202 Accepted for async operations.
"op_01HXYZ8A6N7K2W9PQ4T5Z3V6E0"
queued "https://api-sandbox.ledgersyncappv2.com/v3/operations/op_01HXYZ8A6N7K2W9PQ4T5Z3V6E0"
Rough ETA for completion. Best-effort.
