feat: hourly rate limits for triggers #8

Merged
space merged 4 commits from feat/hourly-ratelimits into main 2026-04-04 17:25:03 +02:00

4 Commits

Author SHA1 Message Date
80510370b0 docs: add AGENT_HOURLY env variable to README
All checks were successful
Lint and Syntax Check / build (pull_request) Successful in 12s
2026-04-04 17:23:00 +02:00
102c146b60 Delete __pycache__/main.cpython-313.pyc
All checks were successful
Lint and Syntax Check / build (pull_request) Successful in 12s
2026-04-04 17:20:01 +02:00
6ee9d2429c Add __pycache__/ to .gitignore and remove cached pyc file
All checks were successful
Lint and Syntax Check / build (pull_request) Successful in 5s
2026-04-04 17:19:16 +02:00
6532bd250d feat: add hourly rate limits for agent triggers
All checks were successful
Lint and Syntax Check / build (pull_request) Successful in 6s
- Add AGENT_HOURLY env var (default: 60 triggers per hour)
- Track hourly usage in SHSF database with key 'agent_{AGENT_USERNAME}_cooldown'
- Check and increment counter before sending notifications
- Add 'clear_limit' route to reset counter hourly via external trigger

Resolves #4
2026-04-04 17:10:23 +02:00