When uploading an audio clip, using the
sendBirdSelectors.getSendFileMessage(store), encoded with ‘audio/webm’ format, the Sendbird backend stores the file without a file extension. This causes issues when using
<audio> HTML tag to play said audio clip in browsers, specifically the duration of the audio clip is broken due to the missing file extension.
This does not happen though for audio clips send with ‘audio/mpeg’, ‘audio/m4a’ or ‘audio/ogg’. Those get the correct .mp3, .m4a, .oga extensions which prevents the issue above.
.m4a clip uploaded, plainUrl includes the file extension: .m4a
.ogg clip uploaded: plainUrl includes the file extension: .ogg
But the problem: ‘audio/webm’ file. There is no file extension.
This is a rather bigger concern, as it would seem, as the default Chrome MediaRecorder option for recording audio uses this format.
Is there a way for these audio files to be saved with a ‘logical’ file extension, when the audio clip sent is using ‘audio/webm’?