uploads.inline
Add a receipt, invoice or original email in one call, for clients that can't upload to a link: filename, mimeType, contentBase64 (the file's bytes in base64, at most 2 MB), idempotencyKey, and optional receiptFor (the purchase it belongs to, as in uploads.prepare) and paymentAccountId. Oatmilk checks the bytes, stores them privately and starts processing; it returns submissionId and jobId. Retrying with the same key and file is safe. Larger files use uploads.prepare and uploads.confirm.
/api/v1/accounting/uploads.inlinePermissions
Who can call it
Retries
MCP
accounting_uploads_inlineFields
filenamestringRequiredThe file's name, including its extension.
1–255 characters
mimeTypeenumRequiredThe file's type, such as image/jpeg or application/pdf.
image/jpegimage/pngimage/webpimage/heicimage/heifapplication/pdfmessage/rfc822contentBase64stringRequiredThe file's exact bytes, encoded as base64.
4–2796204 characters
claimedMetadatamapidempotencyKeystringRequiredAny unique text you generate once per intended change, so a retried request only happens once. Send it as the Idempotency-Key header instead if you prefer; if you send both they must match.
8–160 characters
paymentAccountIdstring (ID)The card or account the purchase was paid with, from accounts.list.
receiptForstring (ID)The ID of the purchase this receipt is for, from attention.mine or entries.list. The upload is refused unless that purchase still needs a receipt.
receiptBatchIdstring (ID)The ID of the related record.
Example
curl https://app.getoatmilk.com/api/v1/accounting/uploads.inline \
-H "Authorization: Bearer $OATMILK_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"filename": "receipt.jpg",
"mimeType": "image/jpeg",
"contentBase64": "SGVsbG8sIE9hdG1pbGsh"
}'{
"data": {
"submissionId": "4d5e6f7a-8b9c-4d0e-8f1a-2b3c4d5e6f7a",
"jobId": "2b3c4d5e-6f7a-4b8c-9d0e-1f2a3b4c5d6e",
"generation": 1,
"status": "queued",
"sizeBytes": 182734
}
}Try it
Try it
Checks your input with this action’s real schema and answers like the API, with synthetic data. No key needed, and nothing changes.
curl https://app.getoatmilk.com/api/v1/accounting/uploads.inline \
-H "Authorization: Bearer $OATMILK_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"filename": "receipt.jpg",
"mimeType": "image/jpeg",
"contentBase64": "SGVsbG8sIE9hdG1pbGsh"
}'More in Inbox and uploads.