Codebase API Documentation

Uploading Attachments

You can upload files to include with a ticket update or project file creation. If the uploaded image is detected as an image (GIF, JPG or PNG) we'll display it in the web interface.


Data Method URL
Upload a file to your account POST /uploads

Object Properties

POST /uploads


You should upload your attachment as a multipart-form, name the file parameter files[]. You can upload multiple files at once by specifying many files[] parameters.

  • identifier should be used for adding this attachment to a ticket or a project file. Use in the upload-tokens array when creating these objects.

Example for adding an attachment using curl

curl \
  -u "account/user:api_key" \
  -F "files[]=@path/to/file/to/upload.gif;type=image/gif" \
  -F "files[]=@another/file/to/upload2.gif;type=image/png""

If the request is successful, you'll receive a 200 OK with properties for the attachment, otherwise a 422 Unprocessable Entity.