Question

This might be a very simple answer, but I am unfamiiar with the Soundcloud API, so any help would be appreciated.

I am trying to access the Soundcloud API with PHP to access user details. I have obtained a soundcloud CLIENT_ID by activating my app through my personal soundcloud account, but it doesn't seem to work when accessing other public users information.

Does the CLIENT_ID change per user?

Does the app need to be validated/accepted by every user in order to access information such as song list, etc... (or can it be validated once) ?

Was it helpful?

Solution

The CLIENT_ID identifies your application. Requests that include a CLIENT_ID can read any public information. A subset of user information is available with just a CLIENT_ID. For example, the URI:

http://api.soundcloud.com/users/12840173.json?client_id=A_CLIENT_ID

Will return the following JSON:

{
  id: 12840173
  kind: user
  permalink: paultest
  username: paultest
  uri: http://api.soundcloud.com/users/12840173
  permalink_url: http://soundcloud.com/paultest
  avatar_url: http://i1.sndcdn.com/avatars-000015469869-jcyh92-large.jpg?330b92d
  country: Canada
  full_name: Paul Osman
  description: null
  city: Toronto
  discogs_name: null
  myspace_name: null
  website: null
  website_title: null
  online: true
  track_count: 17
  playlist_count: 4
  public_favorites_count: 1
  followers_count: 1
  followings_count: 1
}

In order to access non-public information (e.g. private tracks, account plan, etc) you must have the user authorize your application. For more information on our OAuth implementation, see the documentation for authorizing server-side web applications.

Hope that helps!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top