Skip to content

[v1.2] WebhookHandler should respond to GET (for ALB / K8s health checks) #120

Description

@MaxMansfield

Context

The SDK's WebhookHandler (src/rtms/__init__.py:295 Python; equivalent in Node) only implements do_POST. Python's BaseHTTPRequestHandler defaults to 501 Not Implemented for unimplemented HTTP methods.

This breaks every cloud deployment behind a load balancer:

  • AWS ALB target group health check matchers are hard-capped at 200-499 by AWS. Setting matcher = "200-599" returns: ValidationError: Health check matcher HTTP code '599' must be within '200-499' inclusive. So 501 is unmatchable, targets stay unhealthy, ALB returns 503 to all traffic including legitimate POST webhooks.
  • Kubernetes liveness probes default to GET /healthz — same issue.
  • GCP Load Balancer health checks have similar constraints.

Discovered during AWS Terraform deploy on 2026-05-20 — every cloud deployer hits this. Current workaround in the terraform-template worker/main.py is a WebhookHandler subclass that adds a do_GET returning 200, then rtms.WebhookHandler = subclass. Hack that every customer reinvents.

What to ship

Add do_GET to the SDK's WebhookHandler (both Python and Node). Pick one:

Option Response Pros / Cons
A. 200 OK + {"status":"ok"} body Friendly for any health-probe tool, monitoring uptime checks, etc. Implies a real endpoint at /.
B. 405 Method Not Allowed + Allow: POST header More semantically correct — the webhook server is POST-only Still in 200-499 range, ALB and K8s health checks both accept

Option B is the more honest HTTP. Either resolves the cloud-deploy gap. Recommendation: ship B.

Acceptance criteria

  • Python WebhookHandler.do_GET implemented
  • Node.js equivalent implemented (Node's stock http may not have this exact shape — match the spirit)
  • Returns 405 with Allow: POST header (or 200 if you go with option A)
  • examples/python.md and examples/node.md show the new behavior with an ALB / K8s health-check note
  • Tested behind an actual ALB (matcher 200-299 or 200-499) — targets become healthy

Cross-language parity

  • Python and Node ship same status code (both 405 or both 200)
  • Same response body shape
  • Both updated in the same release
  • PR description includes "Cross-language parity check" section

Source

Tracked in vault: Projects/RTMS SDK v1.2.md → DEVS-X9.

Tracker

Part of the v1.2 milestone. Project: https://github.com/orgs/zoom/projects/11.

Metadata

Metadata

Assignees

No one assigned

    Labels

    DXQuality-of-life or DX improvement to the SDKcloud deployAffects Docker / ECS / Fargate / Kubernetes deploymentslanguage parityRequires parallel implementation in Node.js and Python with parity check in PRv1.2Part of the v1.2 release

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions