SoundCloud.getCurrentUser()

Get the SoundCloud profile data for a user by access token.

Usage

Hover over inputs/exits for more info.

var SoundCloud = require('machinepack-soundcloud');


// Get the SoundCloud profile data for a user by access token.

SoundCloud.getCurrentUser({

accessToken: 'AQDvCav5zRSafS795TckAerUV53xzgqRyrcfYX2i',

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

accessToken required

A valid access token that can be used to access the SoundCloud api.

'AQDvCav5zRSafS795TckAerUV53xzgqRyrcfYX2i'

Exits

error

An unexpected error occurred.

success

OK.

{
  id: 123,
  permalink: 'sbahn-sounds',
  username: 'Doctor Wilson',
  uri: 'http://api.soundcloud.com/comments/32562',
  permalink_url: 'http://soundcloud.com/bryan/sbahn-sounds',
  avatar_url: 'http://i1.sndcdn.com/avatars-000011353294-n0axp1-large.jpg',
  country: 'Germany',
  full_name: 'Tom Wilson',
  city: 'Berlin',
  description: 'Buskers playing in the S-Bahn station in Berlin',
  discogs_name: 'myrandomband',
  myspace_name: 'myrandomband',
  website: 'http://facebook.com/myrandomband',
  website_title: 'myrandomband on Facebook',
  online: true,
  track_count: 12,
  playlist_count: 1,
  followers_count: 416,
  followings_count: 174,
  public_favorites_count: 26,
  plan: 'Pro Plus',
  private_tracks_count: 63,
  private_playlists_count: 3,
  primary_email_confirmed: true
}