For the complete documentation index, see llms.txt. This page is also available as Markdown.

DELETE /v1/knowledge-bases/{knowledge_base_id}/resources/{resource_id}

Delete Resource By Id

delete

Delete a file resource by ID.

How to use

Delete the specified resource from its KB. Verify both IDs before removing content used by downstream retrieval. A 204 has no body.

Authentication and permissions

Required permissions: kbs.delete. Resource and owner access checks also apply.

Authorizations
AuthorizationstringRequired

Personal API key (sk_...) or supported user access JWT. See Authentication and authorization for endpoint restrictions and scopes. Use exactly one Authorization header.

Path parameters
knowledge_base_idstring · uuidRequired
resource_idstring · uuidRequired
Responses
204

Successful Response

No content

delete/v1/knowledge-bases/{knowledge_base_id}/resources/{resource_id}
curl
curl --fail-with-body -sS -X DELETE \
  "$STACKAI_BASE_URL/v1/knowledge-bases/${KNOWLEDGE_BASE_ID}/resources/${RESOURCE_ID}" \
  -H "Authorization: Bearer $STACKAI_API_KEY"

No content

Last updated

Was this helpful?