FastAPI server for Taskdog task management system
Project description
taskdog-server
FastAPI server for Taskdog task management system.
Overview
This package provides a REST API for all Taskdog functionality including:
- Task CRUD operations
- Task lifecycle management (start, complete, pause, cancel, reopen)
- Task relationships (dependencies, tags)
- Time tracking and logging
- Schedule optimization
- Statistics and analytics
- WebSocket real-time updates
Installation
pip install taskdog-server
For development:
pip install -e ".[dev]"
Usage
Start the server:
taskdog-server
With custom options:
taskdog-server --host 0.0.0.0 --port 3000
Development mode with auto-reload:
taskdog-server --reload
API Documentation
Once the server is running, visit:
- Interactive API docs: http://localhost:8000/docs
- Alternative docs: http://localhost:8000/redoc
- Health check: http://localhost:8000/health
For complete API reference, see docs/API.md.
Authentication
Configure API key authentication in ~/.config/taskdog/server.toml:
[auth]
enabled = true
[[auth.api_keys]]
name = "my-client"
key = "your-secret-key"
Clients authenticate via X-Api-Key header:
curl -H "X-Api-Key: your-secret-key" http://localhost:8000/api/v1/tasks/
See Authentication Documentation for details.
WebSocket Real-time Updates
Connect to /ws for real-time task notifications:
const ws = new WebSocket('ws://localhost:8000/ws?token=your-api-key');
ws.onmessage = (event) => {
const data = JSON.parse(event.data);
console.log('Event:', data.type); // task_created, task_updated, etc.
};
Event types:
task_created- New task createdtask_updated- Task fields updatedtask_deleted- Task deletedtask_status_changed- Task status changedschedule_optimized- Schedule optimization completed
Note: WebSocket uses an in-memory connection manager, so the server always runs as a single process.
Configuration
Server configuration: ~/.config/taskdog/server.toml
[auth]
enabled = true
[[auth.api_keys]]
name = "my-client"
key = "your-secret-key"
[audit]
enabled = false
Core configuration: ~/.config/taskdog/core.toml
[region]
country = "JP"
See Configuration Guide for all options.
Architecture
The server uses:
- FastAPI: Modern, fast web framework
- Pydantic: Data validation with type hints
- uvicorn: ASGI server
- taskdog-core: Core business logic and infrastructure
API Routers
tasks.py- Task CRUD operationslifecycle.py- Task status changesrelationships.py- Dependencies and tagsanalytics.py- Statistics and reportingnotes.py- Markdown noteswebsocket.py- Real-time updates
Dependency Injection
Controllers are injected via FastAPI dependencies:
CrudControllerDep = Annotated[TaskCrudController, Depends(get_crud_controller)]
Related Packages
- taskdog-core: Core business logic used by this package
- taskdog-ui: CLI and TUI interfaces connecting to this server
- taskdog-client: HTTP client library for API access
- taskdog-mcp: MCP server for Claude Desktop integration
Testing
pytest tests/
Deployment
Systemd (Linux)
systemctl --user start taskdog-server
systemctl --user enable taskdog-server
Docker
docker pull ghcr.io/kohei-wada/taskdog-server:main
docker run -d -p 8000:8000 -v taskdog-data:/data ghcr.io/kohei-wada/taskdog-server:main
See contrib/README.md for deployment details.
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file taskdog_server-0.19.0.tar.gz.
File metadata
- Download URL: taskdog_server-0.19.0.tar.gz
- Upload date:
- Size: 32.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5bef9a2a84a8bb641bb9b2d43b7657bb3b58f903dad13d562bc95408ecaaa27b
|
|
| MD5 |
9491c28fb61f197be04436641f4634be
|
|
| BLAKE2b-256 |
234fd9e1069e5b4ead837eaabfac9acdeb253734ec1a2dd0af34a8d6bfd4881c
|
Provenance
The following attestation bundles were made for taskdog_server-0.19.0.tar.gz:
Publisher:
release.yml on Kohei-Wada/taskdog
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
taskdog_server-0.19.0.tar.gz -
Subject digest:
5bef9a2a84a8bb641bb9b2d43b7657bb3b58f903dad13d562bc95408ecaaa27b - Sigstore transparency entry: 1436730517
- Sigstore integration time:
-
Permalink:
Kohei-Wada/taskdog@4ed1c1f6592b04ffb8e886829019e2a4651119bb -
Branch / Tag:
refs/tags/v0.19.0 - Owner: https://github.com/Kohei-Wada
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@4ed1c1f6592b04ffb8e886829019e2a4651119bb -
Trigger Event:
push
-
Statement type:
File details
Details for the file taskdog_server-0.19.0-py3-none-any.whl.
File metadata
- Download URL: taskdog_server-0.19.0-py3-none-any.whl
- Upload date:
- Size: 42.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
05912cec1e1cde8f900b26246e3f77e773c582531412674282602b984422e6f7
|
|
| MD5 |
fd8a3c600b99e5d1933ad9c7de707ed7
|
|
| BLAKE2b-256 |
93af44e3a915a73e0027c5518a933aaff4119339908cb7cad9801fef9e38cd16
|
Provenance
The following attestation bundles were made for taskdog_server-0.19.0-py3-none-any.whl:
Publisher:
release.yml on Kohei-Wada/taskdog
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
taskdog_server-0.19.0-py3-none-any.whl -
Subject digest:
05912cec1e1cde8f900b26246e3f77e773c582531412674282602b984422e6f7 - Sigstore transparency entry: 1436730781
- Sigstore integration time:
-
Permalink:
Kohei-Wada/taskdog@4ed1c1f6592b04ffb8e886829019e2a4651119bb -
Branch / Tag:
refs/tags/v0.19.0 - Owner: https://github.com/Kohei-Wada
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@4ed1c1f6592b04ffb8e886829019e2a4651119bb -
Trigger Event:
push
-
Statement type: