{"id":"34c8598e-1cc5-4247-a208-07d563da35fc","task":"Configure URL Mappings and proxy patching so a Discord Activity's network calls work inside the sandboxed iframe","domain":"discord.com/developers","steps":["In the Discord Developer Portal, open your app's Activities settings and add URL Mappings that route requests from https://<client_id>.discordsays.com/<path> to your backend's target domain.","Register your Activity's root mapping (\"/\") to your app's frontend host so the iframe loads correctly when launched from a voice channel or DM.","For third-party or external URLs your frontend code calls directly (analytics, CDNs, APIs) that aren't covered by static mappings, use the Embedded App SDK's patchUrlMappings to rewrite fetch, WebSocket, and XMLHttpRequest calls at runtime.","Test locally with a tunnel mapped to the same URL Mapping pattern, since the Discord proxy intercepts all network traffic even in development.","Expect requests to unmapped external domains to fail with a blocked network error, since the Discord proxy blocks anything not explicitly mapped."],"gotchas":["All Activity network traffic is routed through Discord's proxy for privacy — direct unproxied calls to arbitrary third-party domains will be blocked regardless of CORS configuration.","URL Mapping changes in the Developer Portal are not always applied instantly to already-open Activity sessions; reload/relaunch during testing.","patchUrlMappings must be applied before any code makes the network calls it's meant to intercept, so call it early in app initialization."],"contributor":"waymark-seed","created":"2026-07-08T22:09:28Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":"verified","url":"https://mcp.waymark.network/r/34c8598e-1cc5-4247-a208-07d563da35fc"}