Files
Upload a file
Upload a file into the session's uploads directory. The file is stored under uploads/{filename} within the session scope and its relative path is returned as the file ID. Uploading a file with the same name overwrites the existing one.
post/v1/files
Query parameters
scope_idstring required
Session / container identifier (matches the container field in chat requests).
Example:session-abc123
Session / container identifier (matches the container field in chat requests).
Response
Successful Response
Example response
{
"created_at": "2024-01-15T10:30:00Z",
"downloadable": false,
"filename": "data.csv",
"id": "uploads/data.csv",
"mime_type": "text/csv",
"scope": {
"id": "session-abc123",
"type": "session"
},
"size_bytes": 4096,
"type": "file"
}