Fichiers
Référence OpenAPI générée pour le domaine « Fichiers ».
Return stored binary content with safe download headers and its MIME type.
Text-only files and paths without stored binary content return HTTP 404.
Path Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/file-content/string"nullConvert a file to the requested format and stream it back as a download.
Requires permission to view workspace files; the conversion is read-only and never writes the result back to the workspace.
Path Parameters
Query Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/file-export/string?format=string"nullcurl -X GET "https://example.com/api/workspaces/string/file-versions/string"{ "versions": [ { "created_at": "string", "created_by_agent": "string", "created_by_user": "string", "version": 0 } ]}Path Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/file-versions/string/0"{ "content": "string", "created_at": "string", "version": 0}List visible files, including linked client files and shared skills where applicable.
Path Parameters
Query Parameters
false""Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/files"[ { "accent_color": "string", "mime_type": "string", "path": "string", "size": 0, "source": "workspace" }]Claim a pending upload and enqueue asynchronous file processing.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/files" \ -H "Content-Type: application/json" \ -d '{ "upload_id": "string" }'{}Move files or folder trees to trash as one recoverable batch.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X DELETE "https://example.com/api/workspaces/string/files" \ -H "Content-Type: application/json" \ -d '{ "paths": [ "string" ] }'{ "batch_id": "string", "deleted": 0}Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/files/download" \ -H "Content-Type: application/json" \ -d '{ "paths": [ "string" ] }'nullMove file trees, including across linked private workspaces; requires edit permission.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X PATCH "https://example.com/api/workspaces/string/files/move" \ -H "Content-Type: application/json" \ -d '{ "destination": "string", "paths": [ "string" ] }'{ "moved": 0}Issue a time-limited upload URL; requires permission to create workspace files.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/files/presign" \ -H "Content-Type: application/json" \ -d '{ "content_type": "string", "filename": "string", "size": 0 }'{ "expires_at": "string", "headers": {}, "upload_id": "string", "url": "string"}Rename a file or folder tree with edit permission, rejecting path collisions.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X PATCH "https://example.com/api/workspaces/string/files/rename" \ -H "Content-Type: application/json" \ -d '{ "new_name": "string", "path": "string" }'{ "new_path": "string"}Read workspace content with fallbacks for system and tenant-shared skill files.
Path Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/files/string"{ "content": "string", "content_revision": 0, "file_id": "string", "marker_state": {}, "mime_type": "text/plain", "path": "string", "restored_passage_ids": [ "string" ]}Save a user edit with edit permission, guarding shared skill changes against conflicts.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X PUT "https://example.com/api/workspaces/string/files/string" \ -H "Content-Type: application/json" \ -d '{ "content": "string" }'{ "content": "string", "content_revision": 0, "file_id": "string", "marker_state": {}, "mime_type": "text/plain", "path": "string", "restored_passage_ids": [ "string" ]}Create a folder with file-creation permission, returning 409 when it already exists.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/folders" \ -H "Content-Type: application/json" \ -d '{ "path": "string" }'{ "path": "string"}Search across workspace content; queries shorter than two characters return no results.
Path Parameters
Query Parameters
""20Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/search"{ "results": [ { "conversation_id": "string", "id": "string", "snippet": "string", "title": "string", "type": "string" } ]}List recoverable trash entries; requires permission to delete workspace files.
Path Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/workspaces/string/trash"{ "entries": [ { "delete_batch_id": "string", "deleted_at": "2019-08-24T14:15:22Z", "deleted_by_agent": true, "deleted_by_user_id": "string", "id": "string", "mime_type": "string", "original_path": "string" } ]}Permanently purge selected or all trash entries; requires workspace settings permission.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X DELETE "https://example.com/api/workspaces/string/trash" \ -H "Content-Type: application/json" \ -d '{}'{ "purged": 0}Restore selected entries or a deletion batch, renaming paths when collisions occur.
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/trash/restore" \ -H "Content-Type: application/json" \ -d '{}'{ "restored": [ { "original_path": "string", "renamed": true, "restored_path": "string", "trashed_file_id": "string" } ]}