MisterHazza
MisterHazza

Reputation: 198

What is the Content-Type for mp3 files in node.js?

I am trying to code a web server, using the node.js 'http' module. Can anyone tell me what the 'Content-Type' header value is for mp3/audio files is? For example:

response.writeHead(200, "OK", {"Content-Type": "audio/mp3"});

I hope I explained myself well. Thanks

Upvotes: 2

Views: 2666

Answers (1)

Rachit Anand
Rachit Anand

Reputation: 664

It is audio/mpeg.

I usually search for mime types to find out what should be sent as the Content-Type header for files.

--UPDATE--

Reading a bit more about Mime-Types, it is infact 'mime-type' that we send as Content-Type header for files.

Upvotes: 2

Related Questions