diff --git a/server/reflector/views/transcripts.py b/server/reflector/views/transcripts.py index 410839d7..10e30b26 100644 --- a/server/reflector/views/transcripts.py +++ b/server/reflector/views/transcripts.py @@ -356,10 +356,14 @@ async def transcript_get_audio_mp3( if not transcript.audio_mp3_filename.exists(): raise HTTPException(status_code=404, detail="Audio not found") + truncated_id = str(transcript.id).split("-")[0] + filename = f"recording_{truncated_id}.mp3" + return range_requests_response( request, transcript.audio_mp3_filename, - content_type="audio/mp3", + content_type="audio/mpeg", + headers={"Content-Disposition": f"attachment; filename={filename}"}, ) diff --git a/www/app/transcripts/recorder.tsx b/www/app/transcripts/recorder.tsx index a550a840..c1ba0774 100644 --- a/www/app/transcripts/recorder.tsx +++ b/www/app/transcripts/recorder.tsx @@ -311,6 +311,9 @@ export default function Recorder(props: RecorderProps) {