Skip to main content
 print this page

List, download, or preview files

GET 

/ai/playground/files

Omit action (or any value other than download/preview) to list files. List with chat_id returns that chat's files plus global files (chat_id is used as-is; pass project-files-{project_id} to list a project's files). List without chat_id returns accessible chat, project, and global files. Default offset 1, limit 5000 (max 5000), sortby UploadTime, sortorder desc. action=download or preview requires file_name; chat_id defaults to the user's global files (use global). project_id (not N/A) targets project files. Preview of csv/tsv/txt/json/sql returns {data}; otherwise {PresignedURL}. No request body.

Request

Responses

List returns paginated files. download/preview returns PresignedURL, except preview of csv/tsv/txt/json/sql which returns data.

Response Headers
    Access-Control-Allow-Origin
    Access-Control-Allow-Methods
    Access-Control-Allow-Headers