Info / webinar integration notes
For the webinar app, use iceTransportPolicy: "all" so the browser can use host and STUN server-reflexive paths first, then TURN relay only if direct connectivity fails.
const ice = await fetch('api.php?action=turn', {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({ channel: room })
}).then(r => r.json());
const pc = new RTCPeerConnection({
iceServers: ice.v.iceServers,
iceTransportPolicy: 'all'
});
Error 701 is counted as a STUN warning. If server-reflexive candidates appear, STUN is working even if some STUN URLs/interfaces fail.
Relay classification uses candidate.url when available. Relay candidate ports are usually allocated high ports, so the tester looks at the TURN URL, not the relay port.