wise-white•4mo ago
Upload files to a vapi manages knowledge base via api
Hi there is there currently any way to upload a file and give an existing assistant access to it in the same manner as you can via the vapi dashboard but via api?
Thanks
4 Replies
Yes, you can upload a file to Vapi via the API using the following cURL command:
This will upload your file and return a file ID. However, the documentation does not specify how to directly associate this file with a knowledge base or update an assistant's access via API, so further steps may require dashboard actions or additional API endpoints not covered here.
Sources:
- Vapi API Reference: Upload File
- Vapi API Reference: List Knowledge Bases
- Vapi API Reference: Get Knowledge Base
- Vapi API Reference: Create Assistant
⤵️ Mention @Vapi Support Bot for follow-ups 🐥
deep-jade•4mo ago
Yes, via the Vapi API you can upload files using the /file endpoint, create a KB with those files, and then attach that KB to an existing assistant for access..
wise-whiteOP•4mo ago
Would you mind pointing me to where thats explained in the api docs? I can only see on the knowledge base create endpoint that theres config for trieve or for a custom knowledge based using my server https://docs.vapi.ai/api-reference/knowledge-bases/create
Hey jack, you can follow this documentation on how to create a knowledge base using API: https://docs.vapi.ai/knowledge-base/using-query-tool