Files
Generate file upload URL
Generate a presigned URL for uploading files to use with an agent or a task
POST
Generate file upload URL
Generates a presigned URL that can be used to upload files directly to Wordsmith’s storage. This is the first step when you want to include file attachments with agent questions, or attach files to a task.
Authentication
This endpoint requires a valid API key in the Authorization header.Request body
The MIME type of the file (e.g., “application/pdf”, “text/plain”,
“application/vnd.openxmlformats-officedocument.wordprocessingml.document”,
“image/png”, “audio/mp3”)
Supported file types
Wordsmith supports a wide variety of file formats including:- Documents: PDF, DOC, DOCX, TXT, MD, HTML
- Spreadsheets: XLS, XLSX, CSV, TSV
- Presentations: PPT, PPTX
- Images: PNG, JPEG, WebP, TIFF, HEIC, HEIF
- Audio: MP3, MP4, M4A, MPEG, WAV, WebM
- Archives: ZIP
Response
The unique identifier for this upload job. After you upload the file, pass it as
upload_job_id
in an agent question’s attachments, or as upload_job_id in attachments when you
attach files to a task or add a task comment or thread reply.
Each job_id can be used once.Complete upload flow
After receiving the upload URL, you need to upload your file:Error responses
See the Errors page for the full error format reference.File size limits
- Maximum file size: 1 GB per file. A larger file is refused with
upload_too_largewhen it is attached - Maximum total attachments per question: 10 files
- Files are automatically deleted after 30 days for security
Notes
- Upload URLs expire after 1 hour
- Files must be uploaded using a PUT request with the exact content type specified
- Pass the
job_idasupload_job_idinattachments, on agent questions and on the task file, comment and thread reply endpoints - Each
job_idcan be used once. Using it creates the file; the task response lists the new file’sid
Generate file upload URL