Attach receipt to expense
attach_expense_receiptAttach the original receipt (photo or PDF) to an existing expense (gasto), so it is archived with it and goes into the gestoría export, exactly like the upload in the web app. Existing files stay; an expense holds at most 5 files (e.g. invoice plus delivery note, or a two-page ticket as two photos). contix only stores the file, it does not read it: enter the amounts with create_expense / update_expense first. Accepted: JPG, PNG, WEBP, HEIC, PDF, max 10 MB. Returns the expense id, the stored file name and how many files the expense now holds.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filename | No | original file name, e.g. ticket-repsol.jpg | |
| mime_type | No | optional; detected from the content if missing | |
| expense_id | Yes | expense id from create_expense or list_expenses | |
| file_base64 | Yes | the file content, base64-encoded (no data: prefix needed) |