Default Audio to phone

Hi
I am working on calling app and using jitsi source code. in app user can do Audio Call and Video Call.
In video call Audio set to Speaker by default which is correct but on Audio calls I wanted to set the Audio default to Phone earpiece.
Can somebody help me how and where I can do the modifications to achieve the behaviour, I am working inside jitsi source code.

Any help or snippets would be great.
Thanks