SoundCloud

SoundCloud API access: registration and public metadata

How to get official SoundCloud app credentials, when to use Social Fetch for public metadata, and how to read profile and track results.

Social FetchUpdated

SoundCloud's official API and Social Fetch's public metadata routes have different credentials and capabilities. This guide helps you choose between them, then fetch a public artist profile with Social Fetch.

Is SoundCloud API registration closed?

SoundCloud's current Get an API key page describes registering an app with an Artist Pro subscription. Older instructions saying registration is closed do not describe that documented process.

For official access, follow that page to create an app through SoundCloud's CLI or Your Apps browser workflow. Keep the Client Secret private, then follow the authentication guide to obtain an access token. Registration and an access token are separate steps.

Account screenshot pending. Follow SoundCloud's current registration instructions for the official setup.

Choose the access you need

Your taskAccess to use
Upload tracks or act on a connected user's accountOfficial SoundCloud API with the user's authorisation
Build against SoundCloud's public resourcesOfficial API using its documented client-credentials flow
Fetch public artist profiles and track metadata through Social FetchSocial Fetch API key
Play audio in your applicationSoundCloud's documented playback or widget options

The official API guide covers public resources as well as user-authorised actions. Social Fetch is another option for public metadata; it does not replace SoundCloud account permissions.

Review SoundCloud's API terms and the policies that apply to your use. Public visibility alone does not grant permission to redistribute data or audio.

Try a public profile in the Playground

You'll need a Social Fetch account with credits. You can test in the Playground before creating an API key for your code.

  1. Open the Playground.
  2. Find Get SoundCloud profile in the endpoint selector, or open the profile request.
  3. Enter kehlanimusic as the handle. Use the username from the profile URL, rather than the full URL or display name.
  4. Click Send. This runs a paid lookup. Read the response, rather than the static Example response.
  5. Check data.lookupStatus. For found, the profile is in data.profile and counts are in data.metrics.
Real SoundCloud profile request in the Social Fetch Playground, with the handle input and found lookup status annotated.
Use the profile handle and check lookupStatus before saving the result.
The same real profile response scrolled to metrics and creditsCharged, with both fields annotated.
Counts belong to data.metrics. meta.creditsCharged records this request's charge.

Counts describe the returned snapshot. A null count means unavailable, so keep it distinct from a measured zero. Store meta.requestId with your result if you need to investigate it later.

Make the request from code

Create a key on API keys and store it as SOCIALFETCH_API_KEY in your environment. Keep keys in server-side code. The API key guide explains setup.

In a Bash-compatible shell:

Request
bash

For the TypeScript SDK, install it in your Node project:

Request
bash

Save this as soundcloud.mts, then run npx tsx soundcloud.mts. It makes one profile request and reads the SDK's Result value:

Request
typescript

Automatic retries are off by default. The SDK's optional retryOnRetryAfter setting can honour retry instructions; see SDK configuration. Fix authentication, validation or credit errors before retrying.

Read tracks and pagination

To list public uploads, use profile tracks. The SDK method is client.soundcloud.listProfileTracks({ handle: "kehlanimusic" }).

Real SoundCloud track-list response in the Playground, scrolled to hasMore and the charge for that page.
Pagination belongs to data.page. Each completed page is a separate billed request.

Start without cursor. If data.lookupStatus is found, process data.tracks. Request another page only when data.page.hasMore is true and data.page.nextCursor is a non-null string. Pass that exact value as cursor with the same handle. Do not decode or construct cursors, and give batch jobs a page or credit budget.

The list accepts cursor; there is no documented limit or sort parameter. Deduplicate tracks by id if you collect across runs. For a single track, use track by URL:

Request
bash

The SDK equivalent is client.soundcloud.getTrack({ url: "https://soundcloud.com/kehlanimusic/lights-on-feat-big-sean" }). Read data.track after checking the result and lookup status. durationMs is milliseconds. url links to a SoundCloud page; downloadable is metadata. Neither field supplies an audio file or playback token.

Handle missing data and errors

HTTP 200 means a lookup completed, including a miss. SoundCloud routes expose found and not_found; they do not promise a separate private-account status or a reason why a target was not found.

ResultWhat to do
Profile not_foundExpect profile: null and metrics: null; check the handle
Track not_foundExpect track: null; check the public track URL
Track list not_foundExpect tracks: [], nextCursor: null, hasMore: false; check the handle
found with nullable fieldsPreserve null; do not turn unavailable metrics into zero
HTTP 400, bad_requestCorrect the handle, track URL or cursor using the error details
HTTP 401, unauthorizedCheck the Social Fetch API key
HTTP 402Read the error code for credits or a key spending limit; see Credits
HTTP 502, lookup_failedKeep the error request ID; do not save this as a missing profile
HTTP 503, temporarily_unavailableRetry with backoff, honouring Retry-After when present

A completed profile lookup, track lookup or track-list page costs 1 credit, including not_found. Errors and unavailable fields are different outcomes. Read meta.creditsCharged on successful responses and error.requestId on API errors. See Errors for the shared error envelope. If a request keeps failing, contact support with its request ID.

Share this article