Last updated: 2026-07-31
This is the single consolidated Knowledge Base document for the English docs tree.
The Knowledge Base API stores support cases and reusable solutions with optional AI-enriched fields.
Use header-based auth:
Authorization: Bearer YOUR_JWT_TOKENX-Knowledge-Base-API-Key: YOUR_API_KEY/api/v1/knowledge-base
GET /api/v1/knowledge-base - list own entries (page, per_page, search)POST /api/v1/knowledge-base - create entryGET /api/v1/knowledge-base/{id} - get one owned entryPATCH /api/v1/knowledge-base/{id} - update owned entryDELETE /api/v1/knowledge-base/{id} - soft delete owned entryGET /api/v1/knowledge-base/stats - entry stats for current userGET /api/v1/knowledge-base/publicGET /api/v1/knowledge-base/public/{id}POST /api/v1/knowledge-base/webhook/ingest - single entry ingestPOST /api/v1/knowledge-base/webhook/batch - batch ingest (up to 50 entries){
"title": "Password reset: email not delivered",
"raw_content": "Original support content",
"raw_metadata": {
"source_url": "https://support.example.test/tickets/123"
},
"ai_interpreted_problem": "User does not receive reset email",
"ai_interpreted_solution": "Verify mailbox filters and resend token",
"ai_summary": "Reset flow recovered after mailbox checks",
"ai_keywords": ["password", "mail", "reset"],
"source_type": "manual",
"source_data": {
"session_id": "example-session-id"
},
"is_public": false
}
# Create
curl -X POST https://tools.tornevall.net/api/v1/knowledge-base \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"title":"Test entry","raw_content":"Test","source_type":"manual"}'
# List
curl https://tools.tornevall.net/api/v1/knowledge-base \
-H "Authorization: Bearer YOUR_JWT_TOKEN"
# Public list
curl https://tools.tornevall.net/api/v1/knowledge-base/public
await fetch('https://tools.tornevall.net/api/v1/knowledge-base/webhook/ingest', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-Knowledge-Base-API-Key': 'YOUR_API_KEY'
},
body: JSON.stringify({
title: 'Support session #123',
raw_content: '<html>...</html>',
ai_interpreted_problem: 'User cannot sign in',
ai_interpreted_solution: 'Reset password and confirm mailbox',
source_type: 'copilot',
is_public: false
})
});