I am assigning the soundcloud Playlists tracks to the variable "audios".But when i am trying to access the individual tracks objects form audios it says undefined.
<script src="https://connect.soundcloud.com/sdk/sdk-3.3.2.js"></script>
<script>
SC.initialize({
client_id: 'e0daf19e8a6cb0b30ab12bf9ea4df192'
});
var i=348525692;
var all_tracks=[];
var audios =new Array();
//invoking playlist no: 348525692
audios = SC.get('/playlists/'+i).then(function(playlist) {
return playlist.tracks;
}
);
// Receiving the tracks of the playlist invoked
console.log(audios);
</script>
Which produces below output.
and when i use audios.length or audios.id etc. it says undefined. I want to access this data inorder to proceed ahead with my tasks. Please help.