API supports file uploads. But you can’t use it arbitrarily - it currently supports file uploads via Assistants, Fine-tuning, and Batch API (batch API uploads are only for .jsonl files). See here for more info.
If you require file uploads as part of some kind of knowledge-based or retrieval-based solution, then I recommend Assistants API.
Thank you for your previous response regarding file upload support. I would like to clarify my request: I am specifically interested in the ability to upload and use files within the Chat (Conversation) API.
Currently, it seems that file uploads are only supported via the Assistants API, Fine-tuning, and the Batch API. However, my requirement is to enable users to upload files via the Chat API for real-time analysis and processing. I feel that the Assistants API is more suited for building knowledge-based solutions, particularly in business-to-business (B2B) scenarios, rather than handling frequent user-uploaded documents for analysis.
Given that my use case involves frequent file uploads and analysis by users, I would like to know if there are any plans to introduce file upload functionality in the Chat API.
Somewhat true. But you can create a frontend that lets user upload file and right after the file upload, start your conversation with the Assistant based on file. To do this, you’ll need to attach your file to thread, instead of Assistant.
So, an option is to upload into the knowledge base a file, then get the ID, and then, add that file ID into the message?
Looks nice, also we need to get a dictionary or list of all the files that a user add by his own to manage them properly and delete them to avoid any legal instance.