invoices

Add an attachment to an invoice

Adds an attachment to an existing draft invoice. The attachment will be added last in the list of attachments on the invoice. Attached files will appear as additional pages in the final invoice

Supported file types: jpeg, png and pdf

Show example of multipart MIME as we do for uploads

NOTE: The invoice must be in draft status. Maximum file size is 4 MB and all files can't exceed 10 MB. Dimensions must be less than height of 7016 and width of 4960 in pixels

Scope: invoices:write

post/companies/{companyId}/invoices/{invoiceId}/attachments

Request

  • Base URL
    https://api.bokio.se/v1
  • URL
    https://api.bokio.se/v1/companies/{companyId}/invoices/{invoiceId}/attachments
  • Auth
    • HTTP bearer
    • or OAuth 2
      Authorization code: /authorize
      Client credentials
      Token URL: /token scopes: invoices:read

Headers

Content-Typestring required

Content type of the request

Request body multipart/form-data

filestring binary required

The file to attach to invoice

Response

Attachment added to invoice

idstring uuid
invoiceIdstring uuid
fileNamestring

Example response

{
  "id": "240a4af0-edfd-47b1-b4ab-f30450eaac19",
  "invoiceId": "a419cf69-db6f-4de9-992c-b1a60942a443",
  "fileName": "myfile.pdf"
}

Changes

No recorded changes to this operation across all 2 revisions of this API.