Convert Bank Statement
convert_statementConvert a bank statement PDF into structured data or a spreadsheet. When the user attaches a PDF in the conversation, it arrives automatically as pdf_file — never encode it yourself. Otherwise, pass pdf_url for a public HTTPS link. If your host has no way to reference the attached file at all (no pdf_file/pdf_url equivalent), call request_upload first and pass its upload_id here instead. The base64 pdf parameter is a last resort only, for a caller with no other way to reference the file. To convert several statements in one call, pass upload_ids (the array from a single request_upload call made with count set) instead of pdf/pdf_url/pdf_file/upload_id — mutually exclusive with those four. This batch form only ADMITS each file (queues it, or reports an already-completed duplicate) and returns immediately with a compact per-file status list plus a summary — it never waits for conversion, so call get_statement per document_id once ready rather than expecting inline results here. Returns accounts, transactions, and metadata. output_format "json" (default) returns the data inline, renderable in chat. The other formats (csv, xlsx, qbo, xero) return a time-limited download link instead: present it as a normal link. Every response includes a "summary" field: use it as the single source of truth for what happened. If the conversation is not in English, translate it faithfully into the conversation language; never add details it doesn't contain. Never echo raw status values (e.g. "completed") or field names. Consumes credits (1 per page). Page limit depends on your plan.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| No | |||
| pdf_url | No | ||
| password | No | ||
| pdf_file | No | ||
| upload_id | No | ||
| upload_ids | No | ||
| output_format | No | json |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hint | No | ||
| error | No | ||
| gating | No | ||
| status | Yes | ||
| columns | No | ||
| message | No | ||
| results | No | ||
| summary | No | ||
| dataMode | No | ||
| document | No | ||
| warnings | No | ||
| exportUrl | No | ||
| documentId | No | ||
| extraction | No | ||
| pagination | No | ||
| processedAt | No | ||
| transactions | No | ||
| confidenceScore | No | ||
| processingTimeMs | No | ||
| transactionCount | No |