How to get stream data from producer on server side to pipe to fluent-ffmpeg

Hello,

I’ve developped a live streaming app using mediasoup but I’m having trouble understanding how data flows from producer to consumer on the server side.
I’d like to get the producer video stream on the server and process it with fluent-ffmpeg library.

I tried trace events, I looked for data events, I found old posts about “rtppacket” or “rtp” or other events that don’t appear in the documentation.

I also tried to use the mediasoup-demo github code as help but it didn’t work, and I don’t want to use ffmpeg with shell commands but with the fluent-ffmpeg library.

Maybe I missed something in the documentation. If so, can you point me in the right direction please ?

TL;DR : How can I access the streaming data being sent by the producer on the server side with mediasoup ?

Thanks in advance for your help :slight_smile:

I managed to make it work thanks to the record demo here, as it was referenced several times in other posts on this forum

https://github.com/ethand91/mediasoup3-record-demo

I just had a hard time understanding how it worked