currently im writing a script using PJSUA2 in Python3. The goal of the script is to make voice-calls using SIP. The script is working so far. With createRecorder()
and createPlayer()
and transmitting to them I'm able to record the calls and play some wav Files.
The problem is now I don't have any idea to access the audio data in real time. I want to pass the audio stream to an API and stream back the result.
After some research if found in the documentations something like this: https://www.pjsip.org/pjmedia/docs/html/group__PJMED__STRM.htm#ga67575c8e7b15e325b98ebaa89639b550
But I don't have any idea to use this in Python