unable to delete knowledge base
# support
s
Tried deleting the knowledge base using a delete api call but it doesnt get deleted. Tried multiple deletes and i see a 200 but it doesnt actually get deleted. Example of a kb that doesnt get deleted api.vapi.ai/knowledge-base/b1aa3484-cfb8-480f-a919-1b73905ebb5a
v
It sounds like you're running into a common issue where the DELETE API call returns a 200 status but the knowledge base isn't actually being deleted. Here are a few things to check: 1. **Soft Delete vs. Hard Delete**: Sometimes, the API might be performing a soft delete, which means the knowledge base is not fully removed from the system. You may need to perform a hard delete from the backend. If this is the case, contacting VAPI support might be necessary for complete removal. 2. **Response Processing Issues**: Ensure that the response from the API is formatted correctly. Issues like extra spaces in the JSON response or incorrect content-type settings can lead to unexpected behaviors. 3. **Cache Problems**: Sometimes, caching issues can make it seem like the knowledge base still exists. Try checking in different browsers or clearing your cache to see if that resolves the issue. 4. **Authorization and Permissions**: Make sure that the Bearer token you are using has the necessary permissions to delete the knowledge base. If the token is invalid or lacks the right permissions, it could lead to issues. 5. **Check Server Logs**: If possible, access the server logs to see if there are any errors or discrepancies that could indicate why the deletion isn't happening. If you've checked all these and are still having trouble, it might be best to reach out to VAPI support with the details of your API calls and the knowledge base ID you're trying to delete. They can provide more specific guidance based on your situation. Let me know if you need any more help! 😊 Sources: - [Common Reasons for a DELETE API Call Returning a 200 Status](https://discord.com/channels/1211482211119796234/1211483291191083018/1337314227857391627) - [Troubleshooting Issues with the Delete API Call](https://docs.vapi.ai/api-reference/knowledge-bases/delete) - [Detailed Report on Deleting a Knowledge Base in Vapi](https://docs.vapi.ai/api-reference/knowledge-bases/delete)
s
@shraddha we didn't received any api request for deleting the Knowledge base.
Copy code
curl -X DELETE "https://api.vapi.ai/knowledge-base/{id}" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
https://cdn.discordapp.com/attachments/1346036960933838848/1346423871825379408/image.png?ex=67c82272&is=67c6d0f2&hm=390cc383100cdffaee51c6dbc90ca90298d79c89c002c8dbe59ce5c608351f0f&
delete calls are definitely not going through. I'd really like to cleanup my knowledge bases.
even patches arent working for knowledge bases
My assistant e5d3e7f5-cb59-443a-a8c2-3e7aa958642a has both a knowledgebaseid 57982102-2ceb-4034-9f8b-b3c260b0f4e5 and fileids and the two doesnt correspond to each other. The knowledgebaseid has 2 different fileids under it than what is under the assistant.
@Vapi @Shubham Bajaj any response to this?
s
Hey @shraddha as you can see no delete requests if you want I can delete your KB for you just let me know. Also can you share your curl request in DM so I can try it out and see what could be missing. Lastly Apologies for the delay in response. https://cdn.discordapp.com/attachments/1346036960933838848/1347701614055657493/Screenshot_2025-03-08_at_4.13.07_AM.png?ex=67ccc86f&is=67cb76ef&hm=9d69573f5852a90e2afa4f05489f2bbbdb2af94dd98f9f93260bd4a2bcf7f184&