Diwa is an open-source project and simple unofficial API from the Distrowatch site to get some public data of open-source operation systems like Linux, BSD, etc.
bun install
bun run db:migrate
bun run devInteractive API reference at /api/docs. Shows all endpoints, request params, response shapes.
Use diwa in your project? Open a PR to add yourself here.
PRs welcome. Keep it simple — this is a scraper API, not a framework.
Data cached in SQLite for 12 hours. Not real-time with DistroWatch. Cron cleans stale data every hour.
If cache miss → fresh scrape. Response time 1–5s depends on DistroWatch speed, Obscura & Puppeteer overhead.
Requirement: Bun runtime.
# install deps
bun install --production
# build standalone binary (includes Bun runtime, zero system dep)
bun run build
# run migration + start server
bun startBinary ./diwa is self-contained. Deploy with data/ (SQLite DB) and migrations/ (SQL files for initial setup).
NODE_ENV=production bun run src/index.tsRun as daemon with auto-restart.
sudo useradd -r -s /bin/false diwasudo mkdir -p /opt/diwa/data
sudo cp diwa /opt/diwa/
sudo cp -r migrations /opt/diwa/
sudo chown -R diwa:diwa /opt/diwaSave as /etc/systemd/system/diwa.service:
[Unit]
Description=Diwa - Unofficial DistroWatch API
Documentation=https://github.com/zzzul/diwa
After=network.target
[Service]
Type=simple
WorkingDirectory=/opt/diwa
ExecStartPre=/opt/diwa/diwa db:migrate
ExecStart=/opt/diwa/diwa
Restart=on-failure
RestartSec=5
User=diwa
Group=diwa
# Logging — journald
StandardOutput=journal
StandardError=journal
# Log rotation (auto via journald)
# For file-based logging, uncomment:
# StandardOutput=append:/var/log/diwa.log
# StandardError=append:/var/log/diwa.log
# Security
NoNewPrivileges=true
ProtectSystem=strict
ProtectHome=true
ReadWritePaths=/opt/diwa/data
PrivateTemp=true
[Install]
WantedBy=multi-user.targetOr copy from repo:
sudo cp deploy/diwa.service /etc/systemd/system/sudo systemctl daemon-reload
sudo systemctl enable --now diwasystemctl status diwa# tail logs
journalctl -u diwa -f
# last 100 lines
journalctl -u diwa -n 100
# log file (optional, edit service file to uncomment)
# StandardOutput=append:/var/log/diwa.log
# StandardError=append:/var/log/diwa.logsudo systemctl stop diwa
sudo systemctl restart diwadiwa is not affiliated with, endorsed by, or connected to DistroWatch.com. All data is scraped from publicly available pages.
You are responsible for usage of this API. Be respectful toward DistroWatch's servers — don't spam requests. No sponsor. No warranty. Open source under MIT.