# Attachments

An Attachment is a file asset that is attached to another Kantata OX object.  Depending on the type of object,
the file is used or displayed in different ways.  The objects that Attachments can be attached to are:
Post and Expense.
To create an Expense or Post with an Attachment, use the resulting attachment_id from the Attachment creation
request in the parameters of the Expense or Post creation request.

 - [POST /attachments](https://developer.kantata.com/kantata/specification/attachments/create%20attachment.md): There are two different ways to upload file attachments. Direct CDN upload, or Kantata OX server upload. ## Direct CDN Upload Uploading directly to the CDN is a three step process but allows for fast
 - [PUT /attachments/{id}](https://developer.kantata.com/kantata/specification/attachments/update%20attachment.md): This endpoint returns structured Attachment objects. As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the `results` array and will be indexed by ID in the
 - [DELETE /attachments/{id}](https://developer.kantata.com/kantata/specification/attachments/delete%20attachment.md): Destroys an attachment from its subject object. The response will contain no content and an HTTP 204 status code if the request was successful, or a [standard Kantata OX error message](#section/Errors
 - [PUT /attachments/{id}/sync](https://developer.kantata.com/kantata/specification/attachments/sync%20attachment.md): Marks an upload as complete, and verifies its existence on the CDN. This endpoint returns structured Attachment objects. As with all Kantata OX API endpoints, the returned data will be referenced in s
