Audio file type not working with twilio

Hello,
I’m having issues with recording audio files in the browser to use with Twilio. I basically copied the code from this ->
https://developer.mozilla.org/en-US/docs/Web/API/MediaStream_Recording_API/Using_the_MediaStream_Recording_API
for the recorder. What I want to do is save the audio file to my webserver, which is working, then send it to Twilio to make a call using it. The sample code from MDN creates a blob that is encoded as an OGG file, so I changed that line to this:

const blob = new Blob(chunks, { 'type' : 'audio/mp3' });

instead of this:

  const blob = new Blob(chunks, { 'type' : 'audio/ogg; codecs=opus' });

So everything seemed to be working well, I have the file saving to the webserver properly, and the required access to the directory so that there’s no issue using that clip with Twilio. The only thing is Twilio keeps giving me an error when I try to access that file. I know for sure it’s not a directory permissions thing, because when I upload an mp3 music clip to the webserver it works just fine. So my thought is that I’m somehow encoding the mp3 wrong and Twilio doesn’t like it. Does anyone have any experience with this issue or thoughts on how to move forward?

Oh I forgot to mention I’ve also tried audio/wav format as well to no avail.

Thanks!