Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
WebRTC Signaling with Dat
WebRTC, unlike Dat, requires doing a handshake through a third party.
With beaker, that third party can be the existing P2P connections that you have.
To connect between two peers you need to do the following:
- Create a Dat Archive for the call website
- Listen on messages in the [dat-peers API](
- Have the user enter a "room"
- Set up the WebRTC connection, send the SDP handshake and the `room` through datPeers
- When you get messages for your room, pass them to the local PeerConnection as being remote SDP or ICE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment