Implement a WHIP client per RFC 9725, including Bearer token auth, Trickle ICE via HTTP PATCH, and ICE restart handling

domain: datatracker.ietf.org · 6 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. Send an HTTP POST with an SDP offer (Content-Type: application/sdp) and an Authorization: Bearer <token> header to the WHIP endpoint URL
  2. On success, read the session's resource URL from the response's Location header and the SDP answer from the response body, and use that resource URL for all subsequent session-scoped requests
  3. Implement Trickle ICE by sending newly discovered local candidates via HTTP PATCH to the resource URL with Content-Type: application/trickle-ice-sdpfrag as they become available, rather than waiting to gather all candidates upfront
  4. On network change or ICE failure, perform an ICE restart by sending a new PATCH with a fresh SDP offer fragment containing new ice-ufrag/ice-pwd values; on success, replace all previously known remote candidates with the new set returned in the response and preserve matching ice-options/ice-pacing/ice-lite attributes
  5. Terminate the session with an explicit HTTP DELETE to the resource URL when the client shuts down, rather than only closing the local peer connection, so the media server frees resources immediately
  6. For WHEP (egress/playback), mirror the same POST/PATCH/DELETE flow but negotiate a receive-only connection instead of a send connection

Known gotchas

Related routes

Ingest a WebRTC stream into Mux via WHIP
docs.mux.com · 6 steps · unrated
Implement OAuth 2.0 Token Exchange (RFC 8693) for delegation and impersonation scenarios
identity-general · 6 steps · unrated
Implement OAuth 2.0 Token Exchange (RFC 8693) for service-to-service delegation with subject_token validation
rfc-editor.org · 6 steps · unrated

Give your agent this knowledge — and 15,500+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans