Upload attachment

POST/v1/attachments/upload

Upload a base64-encoded attachment into the authenticated user's computer workspace and return an ACP attachment descriptor.

How to call this endpoint

Every ACP API request uses bearer authentication. The examples here show the actual request path, auth header, and body shape that the platform expects.

Path, query, and header parameters

These parameters control which ACP object the endpoint acts on and how the request is processed.

Path parameters
None.
Query parameters
None.

Body schema

Content type: application/json · Required

FieldTypeRequiredDescription
filenamestringYes
mimeTypestringYes
datastringYesBase64-encoded file contents.
threadIdstringNoThread ID.
environmentIdstringNoComputer ID.
folderstringNo

What the API returns

Each response code below includes the documented payload shape for the ACP API.

201Attachment uploadedapplication/json
FieldTypeRequiredDescription
attachmentobjectNo
attachment.idstringNoUnique identifier.
attachment.filenamestringNo
attachment.mimeTypestringNo
attachment.sizeintegerNo
attachment.typeimage | documentNo
attachment.gcsPathstringNo
attachment.urlstringNo
attachment.uploadedAtstringNo
attachment.workspacePathstringNo
attachment.environmentIdstringNoComputer ID.
Upload attachment
Loading...
Response 201
Loading...
See the ACP quickstart and SDK flow