fastrtc icon indicating copy to clipboard operation
fastrtc copied to clipboard

Add instructions for deploying with Cloudflare

Open mhart opened this issue 21 hours ago • 0 comments

Cloudflare offers a managed TURN service with Cloudflare Calls: https://developers.cloudflare.com/calls/

This adds instructions for generating credentials via the Cloudflare API to plug into a Stream's rtc_configuration.

I've tested these instructions with the echo example (and stream.ui.launch(share=True)).

Further documentation on generating credentials is here:

https://developers.cloudflare.com/calls/turn/generate-credentials/#create-credentials

Unfortunately we don't have a Python API for this, so I've just added instructions for a raw http call with requests.

(yes, the output from the API is a little funky in that it has an iceServers property... but it's a single object, not an array! So we have to wrap it again before passing to Stream, sigh)

mhart avatar Feb 28 '25 12:02 mhart