Upload an attachment
POST/attachments
Uploads a file to the workspace blob registry. Send as multipart/form-data with a file part and an optional title. Requires scope finance.attachments.write. Allowed types: pdf, png, jpg/jpeg, xml, ofx, csv, xlsx; max 10 MB. For PDF/PNG/JPEG the declared MIME must match the payload's magic bytes (mismatch → 422). The response is the same metadata shape as GET /attachments/{id}; link counts start at 0 — associate the file via POST /attachments/{id}/links. No Idempotency-Key support on upload.
Request
Responses
- 201
- 400
- 401
- 403
- 422
- 500
Attachment uploaded. The Location header points at the new row.
Body is not valid multipart/form-data.
Missing / invalid / expired / revoked token.
Token lacks the finance.attachments.write scope.
Missing file part, file too large, disallowed MIME type, or magic bytes that don't match the declared type.
Unhandled server error.