How nithishduda-ai/pagerduty-oncall-ack works
PagerDuty On-Call Ack is a narrow CLI and optional terminal dashboard for checking a configured user’s on-call status and acknowledging only their triggered incidents. The main workflow validates configuration and PagerDuty access, checks on-call eligibility, lists assigned open incidents, then acknowledges eligible incidents only in apply mode; it also supports dry runs and watch mode. The dashboard polls and presents the same state. The implementation is concentrated in cli.py and tui.py; unsampled command details are represented only where the README documents them.
Main entry points: cli.py CLI commands · tui.py Polling dashboard
Components 11
CLI and setup
- CLI commands
src/pagerduty_oncall_ack/cli.py - Configuration
src/pagerduty_oncall_ack/cli.py - Access validation
src/pagerduty_oncall_ack/cli.py
Incident workflow
- PagerDuty client
src/pagerduty_oncall_ack/cli.py - On-call eligibility
src/pagerduty_oncall_ack/cli.py - Assigned incidents
src/pagerduty_oncall_ack/cli.py - Safe acknowledgement
src/pagerduty_oncall_ack/cli.py
Terminal dashboard
- Polling dashboard
src/pagerduty_oncall_ack/tui.py - Dashboard snapshot
src/pagerduty_oncall_ack/tui.py
Other components
- Operator
- PagerDuty REST API
Connections 18
- Operator → CLI commands: runs commands
README.md - Operator → Polling dashboard: opens dashboard
README.md - CLI commands → Configuration: loads settings
README.md - CLI commands → Access validation: dispatches doctor
README.md - CLI commands → PagerDuty client: creates client
src/pagerduty_oncall_ack/cli.py - Access validation → PagerDuty client: validates access
src/pagerduty_oncall_ack/cli.py - PagerDuty client → PagerDuty REST API: sends API requests
src/pagerduty_oncall_ack/cli.py - CLI commands → On-call eligibility: checks schedule
src/pagerduty_oncall_ack/cli.py - On-call eligibility → PagerDuty client: fetches on-calls
README.md - CLI commands → Assigned incidents: lists incidents
src/pagerduty_oncall_ack/cli.py - Assigned incidents → PagerDuty client: fetches incidents
src/pagerduty_oncall_ack/cli.py - CLI commands → Safe acknowledgement: runs eligible ack
src/pagerduty_oncall_ack/cli.py - Safe acknowledgement → PagerDuty client: acknowledges incident
src/pagerduty_oncall_ack/cli.py - Polling dashboard → PagerDuty client: collects state
src/pagerduty_oncall_ack/tui.py - Polling dashboard → Dashboard snapshot: builds snapshot
src/pagerduty_oncall_ack/tui.py - Dashboard snapshot → On-call eligibility: includes status
src/pagerduty_oncall_ack/tui.py - Dashboard snapshot → Assigned incidents: includes incidents
src/pagerduty_oncall_ack/tui.py - Polling dashboard → Safe acknowledgement: acknowledges eligible
src/pagerduty_oncall_ack/tui.py