towerops/lib/towerops_web/controllers/api/v1
Graham McIntire 3b0961dfc0 refactor(webhooks): enqueue Oban jobs immediately, ACK fast
All 4 webhook controllers now verify the signature, insert an Oban job,
and return immediately. Previously, Stripe and PagerDuty did DB queries +
writes inline; Gaiia ran upserts; Agent Release broadcast to all connected
WebSockets — all in the request path.

New workers:
- StripeWebhookWorker — delegates to WebhookProcessor.process/1
- GaiiaWebhookWorker — delegates to Webhooks.process_event/3
- PagerdutyWebhookWorker — resolve/acknowledge alerts by dedup key
- AgentReleaseWebhookWorker — broadcast mass update to agents

Also fix: log error when resolve_alert fails in agent_channel (was silently
discarded, causing "Resolving stuck device_down alert" to repeat in logs).
2026-05-10 17:18:23 -05:00
..
activity_controller.ex feat: expand REST API with alerts, agents, org settings, members, integrations, metrics, activity endpoints 2026-02-14 11:28:57 -06:00
agent_release_webhook_controller.ex refactor(webhooks): enqueue Oban jobs immediately, ACK fast 2026-05-10 17:18:23 -05:00
agents_controller.ex fix: resolve compilation errors, test failures, and credo issues 2026-02-14 12:23:10 -06:00
alerts_controller.ex fix: resolve compilation errors, test failures, and credo issues 2026-02-14 12:23:10 -06:00
check_results_controller.ex reliability-audit-fixes (#181) 2026-03-26 14:10:36 -05:00
checks_controller.ex dialyzer: fix all unmatched_return warnings (154 → 0) 2026-04-21 10:03:55 -05:00
coverages_controller.ex feat(coverage): public REST API + KMZ export + email-on-complete 2026-05-06 17:15:57 -05:00
devices_controller.ex dialyzer: fix all unmatched_return warnings (154 → 0) 2026-04-21 10:03:55 -05:00
escalation_policies_controller.ex feat: add REST API and GraphQL for on-call schedules and escalation policies 2026-03-11 14:01:15 -05:00
gaiia_webhook_controller.ex refactor(webhooks): enqueue Oban jobs immediately, ACK fast 2026-05-10 17:18:23 -05:00
geoip_controller.ex dialyzer: fix remaining 88 warnings — clean dialyzer run 2026-04-21 10:32:42 -05:00
integrations_controller.ex perf+refactor: codebase-wide query and antipattern audit 2026-04-28 16:58:51 -05:00
invitations_controller.ex fix: resolve compilation errors, test failures, and credo issues 2026-02-14 12:23:10 -06:00
maintenance_windows_controller.ex add maintenance windows REST API and GraphQL support 2026-03-11 14:33:25 -05:00
members_controller.ex fix: resolve compilation errors, test failures, and credo issues 2026-02-14 12:23:10 -06:00
mib_controller.ex dialyzer: fix all unmatched_return warnings (154 → 0) 2026-04-21 10:03:55 -05:00
organization_controller.ex fix: use correct auth check for API organization updates 2026-03-10 13:41:38 -05:00
pagerduty_webhook_controller.ex refactor(webhooks): enqueue Oban jobs immediately, ACK fast 2026-05-10 17:18:23 -05:00
schedules_controller.ex feat: add REST API and GraphQL for on-call schedules and escalation policies 2026-03-11 14:01:15 -05:00
sites_controller.ex Refactor duplicate site API logic 2026-03-10 16:27:35 -05:00
stripe_webhook_controller.ex refactor(webhooks): enqueue Oban jobs immediately, ACK fast 2026-05-10 17:18:23 -05:00