Closed samuri51 closed 12 years ago
bot.on('registered', function (data) {
var user = data.user[0];
bot.speak('Welcome in the room : ' + user.name);
});
The data that you receive is there : https://github.com/alaingilbert/Turntable-API/blob/master/turntable_data/registered.js
To get the current dj id, you can get it when you first enter the room.
That is the data that you'll receive : https://github.com/alaingilbert/Turntable-API/blob/master/turntable_data/room_infos.js (search for current_dj)
After that, each time a new song start, you receive a newsong
event. (https://github.com/alaingilbert/Turntable-API/blob/master/turntable_data/newsong.js)
thanks a lot man i was really stumped
hey my question is how would i get the user id of people as they join the room? i need that to be able to display a personalized greeting message. also how do i get the user id of the current djing dj. i see there is a data parameter that is read from, is there anyway for me to view the options in data? thanks for any help you can give.