Skip to main content
POST
/
v2
/
bank-statements
/
upload
Upload a Bank Statement
curl --request POST \
  --url https://api.example.com/v2/bank-statements/upload \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "filename": "<string>",
  "mime_type": "application/json",
  "account_id": "<string>"
}
'
{
  "presigned_url": {
    "url": "<string>",
    "fields": {}
  },
  "statement": {
    "created_at": "2023-11-07T05:31:56Z",
    "modified_at": "2023-11-07T05:31:56Z",
    "id": "<string>",
    "status": "submitted",
    "period_start": "2023-12-25",
    "period_end": "2023-12-25",
    "account_id": "<string>",
    "account_number": "<string>",
    "attachment": {
      "id": "<string>",
      "name": "<string>",
      "src": "<string>",
      "mime_type": "application/json",
      "file_type": "<string>"
    },
    "processing_error": {
      "error_code": "duplicate",
      "error_message": "<string>"
    },
    "transaction_count": 123,
    "total_deposits": 123,
    "total_withdrawals": 123,
    "account_mask": "<string>",
    "currency": "<string>",
    "object": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Request schema for uploading a bank statement.

filename
string
required

Name of the file being uploaded

mime_type
required

MIME type of the file

Available options:
application/json,
application/pdf,
application/msword,
application/vnd.openxmlformats-officedocument.wordprocessingml.document,
application/vnd.ms-excel,
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,
application/vnd.ms-powerpoint,
application/vnd.openxmlformats-officedocument.presentationml.presentation,
text/csv,
application/csv,
text/plain,
text/html,
application/xml,
message/rfc822,
application/vnd.ms-outlook,
application/rtf
account_id
string | null

Bank account ID to associate the statement with

Response

Successful Response

Response schema for bank statement upload.

presigned_url
object
required

Presigned URL for S3 upload.

statement
object
required

Response schema for bank statement list items (no transactions).