7 Commits
Author SHA1 Message Date
1sonhador 0f4bb5f522 feat: BizDocs API delivery, WebDAV source, and invoice validation
Add optional API upload alongside SMTP, Nextcloud/WebDAV as a document source with the same dedup/retry flow as IMAP, stricter invoice file checks for images, and admin UI for source and delivery modes.
2026-07-02 19:21:01 +01:00
1sonhador 9b966cf325 feat: forward queue drains failed messages at 5/min within 200/h cap
Worker ticks every 60s; API and UI expose queue status and requeue of forwarded messages for gradual BizDocs resend.
2026-07-01 10:14:18 +01:00
1sonhador 66d7189aa5 feat: cap SMTP forwards at 200 per rolling hour
Count successful forward_attempts in the last hour and stop sync/retry
when MAX_FORWARDS_PER_HOUR is reached to protect domain sending limits.
2026-07-01 10:09:52 +01:00
XikaandPaperclip 0c63ae7fbd feat: integrate error hub (errors.bitreport.pt) for runtime error reporting
- Add forwarder/error_reporter.py: Python client for v1/ingest/events
  with cooldown-based dedup, best-effort delivery, and env-driven config
- Add FastAPI global exception handler to report unhandled 500s
- Report sync failures and forward failures from sync_service.py
- Report scheduler job failures from worker/scheduler.py with cooldown
- Report startup failures (ensure_admin_user) from app.py
- Report worker crashes from cli.py entry point
- Add error hub env vars to config.py (pydantic-settings)
- Update .env.example with ERROR_REPORTING_TOKEN and related vars
- Exclude IMAP/SMTP connection test errors per BIT-26136 scope note
- Uses project_slug=bizdocs-forwarder, gitea_repo=BitReport.pt/forwarder

Co-Authored-By: Paperclip <[email protected]>
2026-07-01 00:14:29 +00:00
1sonhador f6b276511a fix(connection): fail-fast IMAP/SMTP tests; add Gitea webhook autodeploy
Connection tests use 5s timeouts and run IMAP/SMTP in parallel so the UI
gets a clear error instead of nginx 504. Add deploy-hook service (:9090) and
deploy-pull.sh for push-to-main deploys on CT 243.
2026-07-01 01:09:53 +01:00
1sonhador d1e4725ac3 Add Python API, worker, MySQL migrations and wire admin-ui in Docker.
Backend FastAPI + APScheduler worker with Alembic schema; admin-ui served
via nginx with /api proxy. Unifies Paperclip UI scaffold with local platform code.
2026-07-01 00:04:57 +01:00
spark 09bab7ac0b feat: add .env.example with all required variables (BIT-26128) 2026-06-30 23:53:25 +01:00