{"id":50398363,"url":"https://github.com/medlabib/bedboard","last_synced_at":"2026-05-30T22:00:46.800Z","repository":{"id":361098456,"uuid":"1249488329","full_name":"medlabib/BedBoard","owner":"medlabib","description":"BedBoard helps emergency and ward teams answer one operational question in seconds:  Which beds are available now, who is assigned, and what is the next patient action?","archived":false,"fork":false,"pushed_at":"2026-05-29T07:01:26.000Z","size":45187,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-29T08:22:25.169Z","etag":null,"topics":["bed","emergency","management","medecine","ward"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/medlabib.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"security_health.go","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-25T18:53:26.000Z","updated_at":"2026-05-29T07:01:31.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/medlabib/BedBoard","commit_stats":null,"previous_names":["medlabib/bedboard"],"tags_count":24,"template":false,"template_full_name":null,"purl":"pkg:github/medlabib/BedBoard","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/medlabib%2FBedBoard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/medlabib%2FBedBoard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/medlabib%2FBedBoard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/medlabib%2FBedBoard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/medlabib","download_url":"https://codeload.github.com/medlabib/BedBoard/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/medlabib%2FBedBoard/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33711018,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-30T02:00:06.278Z","response_time":92,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bed","emergency","management","medecine","ward"],"created_at":"2026-05-30T22:00:45.150Z","updated_at":"2026-05-30T22:00:46.785Z","avatar_url":"https://github.com/medlabib.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"backend/logo.svg\" alt=\"BedBoard Logo\" width=\"150\" /\u003e\n\n# BedBoard\n\nA local-first emergency board for bed occupancy and patient flow.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"Release Channel\" src=\"https://img.shields.io/badge/Release%20Channel-beta--1.0.5-8FAADC?style=flat-square\" /\u003e\n  \u003cimg alt=\"Legacy Tags\" src=\"https://img.shields.io/badge/Legacy%20Tags-alpha--v*-B5C7A4?style=flat-square\" /\u003e\n  \u003cimg alt=\"Backend Coverage\" src=\"https://img.shields.io/badge/Backend%20Coverage-26.8%25-7AB893?style=flat-square\" /\u003e\n  \u003cimg alt=\"Frontend Coverage\" src=\"https://img.shields.io/badge/Frontend%20Coverage-32.82%25-6FA7C7?style=flat-square\" /\u003e\n  \u003cimg alt=\"API p95\" src=\"https://img.shields.io/badge/API%20p95-state%203.94ms%20%7C%20patients%208.35ms-D9A66F?style=flat-square\" /\u003e\n\u003c/p\u003e\n\u003c/div\u003e\n\n---\n\nBedBoard is a standalone management system for emergency departments, with role-based access, real-time synchronization, and admin-managed security and UI settings.\n\n## Repository Layout\n\n| Path | Purpose |\n| :--- | :--- |\n| backend/ | Go API server, business logic, persistence, and embedded frontend assets |\n| frontend/ | React + Vite dashboard and admin interface |\n| .github/workflows/ | CI and signed release automation |\n| scripts/ | Utility scripts for local/CI asset synchronization |\n| tools/ | Developer utilities (for example, icon generation) |\n\n## Community and Governance\n\n- Contribution guide: CONTRIBUTING.md\n- Code of conduct: CODE_OF_CONDUCT.md\n- Issue templates: .github/ISSUE_TEMPLATE/\n\nWhen reporting bugs or requesting features, use the provided GitHub templates for faster triage.\n\n## Technology Stack\n\n| Component | Technology |\n| :--- | :--- |\n| Backend | Go, GORM, SQLite |\n| Frontend | React, Vite |\n| Transport | REST, Server-Sent Events (SSE) |\n| Signing | Sigstore Cosign (keyless) |\n\n## Core Features\n\n- Realtime synchronization via SSE endpoint /api/stream.\n- Full patient lifecycle: register, triage, assign, consult, archive.\n- Bed states: free, occupied, cleaning, alert.\n- Role-based access for admin, user, triage, reception, dechocage.\n- White-label branding and localization (French, English, Arabic).\n- Security controls and health checks in-app.\n- Gotify integration with encrypted token support.\n- Outbound SMS/WhatsApp webhook channels with acknowledgement tracking.\n- Patient timeline and operational KPIs (SLA, waits, consultations/hour).\n- Bed assignment dropdown enriched with patient tags (type, triage, status).\n- Extended patient categories including urgences differees.\n\n## Quick Start\n\n```bash\nnpm --prefix frontend ci\nnpm --prefix frontend run build\nbash scripts/prepare-backend-assets.sh\ngo run ./backend\n```\n\nDefault URL: http://localhost:8080\n\n\u003e First login on a fresh database:\n\u003e Username: admin\n\u003e Password: ChangeMe!123\n\u003e\n\u003e Change credentials immediately after login.\n\n## Administration and Security\n\n### Settings Areas\n\n- Parameters: app name, logo, locale, user management.\n- Security: bootstrap credentials, cookie/hsts/proxy controls, health checks.\n- Integrations: Gotify plus SMS/WhatsApp webhook channels and acknowledgement log.\n- Operations: backup/restore and audit management.\n\n### Security Keys\n\n| Key | Description |\n| :--- | :--- |\n| security.admin_init_username | Bootstrap admin username |\n| security.admin_init_password | Bootstrap admin password |\n| security.force_secure_cookie | Force secure session cookies |\n| security.trust_proxy_headers | Trust X-Forwarded-* headers |\n| security.enable_hsts | Enable HSTS policy |\n| security.hsts_max_age | HSTS max-age value |\n| security.hsts_include_subdomains | HSTS includeSubDomains flag |\n| security.hsts_preload | HSTS preload flag |\n| security.gotify_token_enc_key | Encryption key for Gotify token |\n| security.proxy_enabled | Enable outbound proxy for alert integrations |\n| security.proxy_url | Outbound proxy URL |\n| security.proxy_username | Outbound proxy username |\n| security.proxy_password | Outbound proxy password (encrypted) |\n| security.alert_callback_signature_required | Require HMAC signature for public alert callback |\n| security.alert_callback_secret | Shared secret for callback signature verification |\n| security.alert_callback_ip_allowlist | Allowed source IP/CIDR list for callback endpoint |\n| integrations.sms.enabled | Enable SMS outbound channel |\n| integrations.sms.webhook_url | SMS gateway webhook URL |\n| integrations.sms.recipient | SMS default recipient |\n| integrations.whatsapp.enabled | Enable WhatsApp outbound channel |\n| integrations.whatsapp.webhook_url | WhatsApp gateway webhook URL |\n| integrations.whatsapp.recipient | WhatsApp default recipient |\n\n### Security and Operations Endpoints\n\n- Security health: GET /api/admin/security/health\n- Public UI config: GET /api/public/ui-config\n- Admin UI config: GET /api/admin/ui/config, POST /api/admin/ui/config\n- Gotify config: GET /api/admin/integrations/gotify, POST /api/admin/integrations/gotify\n- Gotify test: POST /api/admin/integrations/gotify/test\n- Alert channels config: GET/POST /api/admin/integrations/alerts/channels\n- Alert channels test: POST /api/admin/integrations/alerts/channels/test\n- Alert notifications feed: GET /api/admin/integrations/alerts/notifications\n- Alert acknowledgement (admin): POST /api/admin/integrations/alerts/notifications/ack\n- Alert acknowledgement (gateway callback): POST /api/integrations/alerts/ack\n\nPublic callback security headers (when signature verification is enabled):\n\n- `X-BedBoard-Timestamp`: Unix seconds timestamp\n- `X-BedBoard-Signature`: `sha256=\u003chex(hmac_sha256(secret, timestamp + \".\" + raw_body))\u003e`\n\n## Testing, Coverage, and Performance\n\n### Coverage Snapshot\n\n| Area | Coverage |\n| :--- | :--- |\n| Backend (Go) | 26.8% statements |\n| Frontend (Vitest V8) | 32.82% statements |\n\n### Performance Snapshot\n\n| Metric | Value |\n| :--- | :--- |\n| API /api/state p50 | 2.09 ms |\n| API /api/state p95 | 3.94 ms |\n| API /api/patients p50 | 4.43 ms |\n| API /api/patients p95 | 8.35 ms |\n| collectState benchmark | 2.45 ms/op |\n| Frontend build time | 4.15 s |\n| Frontend JS bundle (gzip) | 66.13 kB |\n\n### Test Commands\n\n```bash\n# Backend\ngo test ./backend/... -coverprofile=coverage.out -covermode=atomic\ngo tool cover -func=coverage.out | awk '/^total:/{print $NF}'\n\n# Performance suites (opt-in)\ngo test ./backend/... -tags perf -run TestAPILatencySnapshot -v\ngo test ./backend/... -tags perf -bench . -benchmem\n\n# Security scanners\ngo vet ./backend/...\ngovulncheck ./backend/...\n\n# Frontend\nnpm --prefix frontend install\nnpm --prefix frontend run test\nnpm --prefix frontend run test:coverage\n```\n\n## Build and Release\n\n### Local Validation\n\n```bash\nnpm --prefix frontend run build\nbash scripts/prepare-backend-assets.sh\ngo build -o /tmp/bedboard ./backend\n```\n\n### Local Release Artifacts\n\n```bash\nset +u\nnpm --prefix frontend run build\nbash scripts/prepare-backend-assets.sh\n\nmkdir -p release\nCGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -ldflags='-s -w' -o release/BedBoard_windows_amd64.exe ./backend\nCGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags='-s -w' -o release/BedBoard_linux_amd64 ./backend\n\nrm -f release/BedBoard_windows_amd64.zip release/BedBoard_linux_amd64.tar.gz release/checksums.txt\nzip -j release/BedBoard_windows_amd64.zip release/BedBoard_windows_amd64.exe\ntar -czf release/BedBoard_linux_amd64.tar.gz -C release BedBoard_linux_amd64\nsha256sum release/BedBoard_windows_amd64.exe release/BedBoard_windows_amd64.zip release/BedBoard_linux_amd64 release/BedBoard_linux_amd64.tar.gz \u003e release/checksums.txt\n```\n\n### Version Channels and Tagging\n\n| Channel | Pattern | Purpose |\n| :--- | :--- | :--- |\n| Beta | beta-* | Active signed release channel |\n| Alpha | alpha-v* | Historical archived tags |\n\nTypical beta release flow:\n\n```bash\ngit add .\ngit commit -m \"release: prepare beta\"\ngit push origin main\ngit tag beta-X.Y.Z\ngit push origin beta-X.Y.Z\n```\n\nThe signed release workflow in .github/workflows/release-signed.yml automatically:\n\n- Builds frontend and backend.\n- Runs security health gate.\n- Packages Linux and Windows artifacts.\n- Generates checksums.\n- Signs artifacts with Cosign.\n- Publishes GitHub Release assets with signature and certificate files.\n\n## Hardware Requirements\n\n| Profile | CPU | RAM | Storage | Notes |\n| :--- | :--- | :--- | :--- | :--- |\n| Minimum | 2 vCPU | 2 GB | 10 GB SSD | Small team, light concurrent usage |\n| Recommended | 4 vCPU | 8 GB | 25 GB SSD | Stable daily operations with better headroom |\n\n## Operational Checklist\n\n1. Rotate default admin credentials immediately.\n2. Configure branding and default locale.\n3. Configure security values and validate health endpoint.\n4. Configure Gotify and send a test notification.\n5. Create role accounts and validate permissions.\n6. Validate backup and restore on a test copy.\n7. Build release artifacts and verify checksums.\n\n## Production Notes\n\n- BedBoard is local-first: protect exposure with strict network controls.\n- Prefer an HTTPS reverse proxy in production.\n- Rotate admin credentials and encryption keys regularly.\n\n## License\n\nThis project is licensed under the GNU Affero General Public License v3.0 (AGPL-3.0).\nSee LICENSE for the full legal text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmedlabib%2Fbedboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmedlabib%2Fbedboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmedlabib%2Fbedboard/lists"}