id3_tobuffer
v1.0.9
Published
Reads and writes ID3 tags for audio to and from buffers
Downloads
11
Maintainers
Readme
ID3 tobuffer
This is a nodejs module to read id3 tags directly from buffer It can also be used to modify ID3 tags and save the information as buffer
No Extra library required to Edit the ID3 TAGS
npm install id3_tobuffer
Include
To use this library simply require the file:
var id3 = require('id3_tobuffer');
Usage
ID3 Reader very easy to use:
Reading tags
id3_reader.read(mp3buffer, function(success, msg, data) {
console.log(data);
})
The output of the above could look something like this:
{
version: '2.3.0',
tags:
{ artist: 'Coldplay',
title: 'A Sky Full Of Stars',
album: 'A Sky Full Of Stars'
}
}
Writing Tags
var tags = {
title: 'Demo title',
artist: 'Demo Artist',
album: 'Demo album',
track_number: '1/8'
}
id3_reader.write(path_to_music_file, tags, function(success, msg data) {
//Data returns the new buffer with the updated tags
})