HTTP API Reference

The kb dashboard server exposes a RESTful JSON API at /api. Use it to integrate kb with other tools, scripts, or custom frontends.

All API routes are served under http://localhost:<port>/api/... (default port 5522).
The server must be running via kb dashboard or kb dashboard --watch.

Routes Overview

MethodRoutePurpose
GET/api/dataFull board data
POST/api/moveChange task status
POST/api/addCreate task
POST/api/delDelete task
POST/api/task-updateEdit task fields
POST/api/task-assignReplace task assignees
GET/api/comments/{task_id}List comments for a task
POST/api/commentsAdd a comment
DELETE/api/comments/{id}Delete a comment
GET/api/usersList users
POST/api/usersCreate user
PUT/api/usersUpdate user
DELETE/api/usersDelete user
POST/api/export/{format}Export board to file
GET/api/export/{format}/downloadExport and download
GET/api/eventsSSE reload stream
GET/api/folderCurrent project folder
POST/api/initInitialize project
POST/api/trash-restoreRestore task from trash
POST/api/trash-cleanEmpty trash
GET/api/configRead config
POST/api/configUpdate config

Board Data

GET /api/data Full board data

Response

{
  "version": 1,
  "config": { "use_trash": true, "theme_dashboard": "dark" },
  "tasks": [ ... ],
  "users": [ ... ],
  "comments": [ ... ]
}
GET /api/folder Current project folder name

Response

"kanban-project"
GET /api/events SSE stream for live reload

Response

text/event-stream — emits "reload" events on data changes

Tasks

POST /api/add Create a task

Request body (JSON)

{
  "title": "Implement login",
  "priority": "high",
  "assigned_to": ["user-uuid"],
  "tags": ["backend", "auth"],
  "due_date": "2026-12-31T00:00:00Z"
}

Response

{ "status": "ok" }
POST /api/move Change task status

Request body (JSON)

{
  "task_id": "uuid",
  "status": "done"
}

Response

{ "status": "ok" }
POST /api/del Delete a task

Request body (JSON)

{ "task_id": "uuid" }

Response

{ "status": "ok" }
POST /api/task-update Edit task title, priority, tags, or due date

Request body (JSON)

{
  "task_id": "uuid",
  "title": "New title",
  "priority": "low",
  "tags": ["frontend"],
  "due_date": null
}

Response

{ "status": "ok" }
POST /api/task-assign Replace task assignees

Request body (JSON)

{
  "task_id": "uuid",
  "assigned_to": ["user-uuid-1", "user-uuid-2"]
}

Response

{ "status": "ok" }

Comments

GET /api/comments/{task_id} List comments for a task

Response

[
  {
    "id": "uuid",
    "task_id": "uuid",
    "author_id": "uuid",
    "content": "Comment text",
    "created_at": "2026-06-25T12:00:00Z",
    "updated_at": null
  }
]
POST /api/comments Add a comment to a task

Request body (JSON)

{
  "task_id": "uuid",
  "author_id": "uuid",
  "content": "Looks good!"
}

Response

{ "status": "ok" }
DELETE /api/comments/{id} Delete a comment permanently

Response

{ "status": "ok" }

Users

GET /api/users List all users

Response

[
  {
    "id": "uuid",
    "username": "alice",
    "pic": "/path/to/avatar.png",
    "created_at": "2026-06-01T10:00:00Z"
  }
]
POST /api/users Create a user

Request body (JSON)

{
  "username": "bob",
  "pic": "/path/to/pic"
}

Response

{ "status": "ok" }
PUT /api/users Update a user's username or pic

Request body (JSON)

{
  "id": "uuid",
  "username": "bob2",
  "pic": "/new/path"
}

Response

{ "status": "ok" }
DELETE /api/users Delete a user (removed from all task assignments)

Request body (JSON)

{ "id": "uuid" }

Response

{ "status": "ok" }

Export

POST /api/export/{format} Export board to file (json or md)

Path parameter

format: "json" | "md"

Response

Writes to .kanban/kb-export.json or .kanban/kb-export.md
GET /api/export/{format}/download Export and download the file through the browser

Path parameter

format: "json" | "md"

Response

File download (Content-Disposition: attachment)

Trash

POST /api/trash-restore Restore a task from trash

Request body (JSON)

{ "task_id": "uuid" }

Response

{ "status": "ok" }
POST /api/trash-clean Permanently delete all trashed tasks

Response

{ "status": "ok" }

Config

GET /api/config Read current config

Response

{
  "use_trash": true,
  "theme_dashboard": "dark"
}
POST /api/config Update config values

Request body (JSON)

{
  "use_trash": false,
  "theme_dashboard": "light"
}

Response

{ "status": "ok" }

Init

POST /api/init Initialize a new project

Response

{ "status": "ok" }