DevelopersAPI referenceCronCrunchExpenses
Upload or replace a receipt
Multipart file for an expense the caller owns. image/jpeg, image/png, image/webp, or application/pdf, at most 8 MB. The bytes are checked against the declared type. Replacing a receipt deletes the previous object. 503 when object storage is not configured.
View as MarkdownAuthorization
bearer AuthorizationBearer <token>
In: header
Path Parameters
id*string
Request Body
multipart/form-data
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/expenses/string/receipt" \ -F file="string"{ "expense": { "id": "string", "clientId": "string", "clientName": "string", "projectId": "string", "projectName": "string", "projectColor": "string", "spentOn": "2019-08-24", "pricing": "amount", "amount": 0, "quantity": 0, "unitRate": 0, "type": "string", "billable": true, "note": "string", "hasReceipt": true, "receipt": { "contentType": "string", "sizeBytes": 0, "filename": "string", "url": "string" }, "created": "2019-08-24T14:15:22Z" }}