PHPackages                             noweh/laravel-soundcloud - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. noweh/laravel-soundcloud

ActiveLibrary[API Development](/categories/api)

noweh/laravel-soundcloud
========================

Soundcloud API Wrapper for Laravel.

2.0.0(1y ago)66.8k↓16.7%3MITPHPPHP &gt;=7.3

Since Oct 27Pushed 1y ago1 watchersCompare

[ Source](https://github.com/noweh/laravel-soundcloud)[ Packagist](https://packagist.org/packages/noweh/laravel-soundcloud)[ RSS](/packages/noweh-laravel-soundcloud/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (1)Versions (8)Used By (0)

SoundCloud API for Laravel
==========================

[](#soundcloud-api-for-laravel)

[![SoundCloud](https://camo.githubusercontent.com/38dce0988f7697c63a6efe30a74a8cb4577cf5476069c0338105e31830586538/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76313f7374796c653d666c61742d737175617265266d6573736167653d536f756e64436c6f756426636f6c6f723d464633333030266c6f676f3d536f756e64436c6f7564266c6f676f436f6c6f723d464646464646266c6162656c3d)](https://camo.githubusercontent.com/38dce0988f7697c63a6efe30a74a8cb4577cf5476069c0338105e31830586538/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76313f7374796c653d666c61742d737175617265266d6573736167653d536f756e64436c6f756426636f6c6f723d464633333030266c6f676f3d536f756e64436c6f7564266c6f676f436f6c6f723d464646464646266c6162656c3d)[![Laravel](https://camo.githubusercontent.com/09d877878370e3a2d75ea8cf0baccff8a3398e90e3750ef471bbbf1ffe31ef2e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d76352f362f372f382f392f31302d3832386362372e7376673f7374796c653d666c61742d737175617265266c6f676f3d4c61726176656c26636f6c6f723d464632443230)](https://camo.githubusercontent.com/09d877878370e3a2d75ea8cf0baccff8a3398e90e3750ef471bbbf1ffe31ef2e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d76352f362f372f382f392f31302d3832386362372e7376673f7374796c653d666c61742d737175617265266c6f676f3d4c61726176656c26636f6c6f723d464632443230)[![PHP](https://camo.githubusercontent.com/d932caa28b1dab8c681c5fbe3eb4cb6ad1facc101241b9efffe47698f774cb55/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d76372e332d3832386362372e7376673f7374796c653d666c61742d737175617265266c6f676f3d706870)](https://camo.githubusercontent.com/d932caa28b1dab8c681c5fbe3eb4cb6ad1facc101241b9efffe47698f774cb55/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d76372e332d3832386362372e7376673f7374796c653d666c61742d737175617265266c6f676f3d706870)[![MIT Licensed](https://camo.githubusercontent.com/0aaac1c5b0682f9b76a4c1dd0a2d9172f1411589c58f2b7b8a2b143cb728fc4f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6e6f7765682f6c61726176656c2d736f756e64636c6f7564)](licence.md)[![last version](https://camo.githubusercontent.com/71658666b4874685ef876787ef1419c97b8cd3a2a91a83a507bdbc36a748abb5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6e6f7765682f6c61726176656c2d736f756e64636c6f7564)](https://packagist.org/packages/noweh/laravel-soundcloud)[![Downloads](https://camo.githubusercontent.com/7201cbc71a3c9e65bda28fe84a61ee23a932478145296896dd624d2b424206ad/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6e6f7765682f6c61726176656c2d736f756e64636c6f7564)](https://packagist.org/packages/noweh/laravel-soundcloud)

A Laravel Wrapper for the SoundCloud REST API endpoints.

Installation
------------

[](#installation)

First, you need to add the component to your composer.json.

```
composer require noweh/laravel-soundcloud

```

Update your packages with *composer update* or install with *composer install*.

Laravel uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.

### Laravel without auto-discovery

[](#laravel-without-auto-discovery)

```
Noweh\SoundcloudApi\SoundcloudServiceProvider::class,

```

To use the facade, add this in app.php:

```
'Soundcloud' => Noweh\SoundcloudApi\SoundcloudFacade::class,

```

### Service Provider

[](#service-provider)

After updating composer, add the ServiceProvider to the providers array in config/app.php

Configuration file
------------------

[](#configuration-file)

Next, you must migrate config :

```
php artisan vendor:publish --provider="Noweh\SoundcloudApi\SoundcloudServiceProvider"

```

⚠️ `{CALLBACK_URL}` must be identical to the one indicated in your SoundCloud account. ⚠️ `{SOUNDCLOUD_CODE_VERIFIER}` must be a random string of 43 to 128 characters: ()

Usage
-----

[](#usage)

⚠️ Since [July 2021](https://developers.soundcloud.com/blog/security-updates-api), most calls to SoundCloud REST API requires an `access_token`. ⚠️ Since October 2024, SoundCloud will require all API calls to be authenticated with an `code_verifier`.

You have to redirect the user to the SoundCloud login page:

```
return redirect(\Soundcloud::getAuthorizeUrl('a_custom_param_to_retrieve_in_callback'));
```

On your callback URL, you can call GET/POST/PUT/DELETE methods. The `access_token` will be automatically generated with the `code` parameter present in this URL.

If you want to use API calls in another page, you have to set manually this data:

```
\Soundcloud::setCode('3-134981-158678512-IwAXqypKWlDJCF');

// API Call
...

```

### Get Player Embed

[](#get-player-embed)

#### This call doest not requires an access\_token.

[](#this-call-doest-not-requires-an-access_token)

To retrieve the widget embed code for any SoundCloud URL pointing to a user, set, or a playlist, do the following:

```
// Required parameter
$url = 'https://soundcloud.com/......';

// Optional parameters
$maxheight = 180;
$sharing = true;
$liking = true;
$download = false;
$show_comments = true;
$show_playcount = false;
$show_user = false;

try {
    $response = \Soundcloud::getPlayerEmbed($url, $maxheight, $sharing, $liking, $download, $show_comments, $show_playcount, $show_user)
} catch (Exception $e) {
    exit($e->getMessage());
}

```

### GET

[](#get)

```
try {
    $response = \Soundcloud::get('users/{CLIENT_ID}/tracks');
} catch (Exit $e) {
    exit($e->getMessage());
}

```

### GET with pagination

[](#get-with-pagination)

Most results from our API are returned as a collection. The number of items in the collection returned is limited to 50 by default with a maximum value of 200. Most endpoints support a linked\_partitioning parameter that allows you to page through collections. When this parameter is passed, the response will contain a next\_href property if there are additional results. To fetch the next page of results, simply follow that URI. If the response does not contain a next\_href property, you have reached the end of the results.

```
try {
    $tracks = [];
    $params = ['linked_partitioning' => true, 'limit' => 100 ];
    $response = \Soundcloud::get('users/{CLIENT_ID}/tracks', $params);
    while (property_exists($response, 'next_href') && !empty($response->next_href)) {
        $tracks = array_merge($tracks,$response->collection);
        $response = \Soundcloud::get($response->next_href);
    }
} catch (Exit $e) {
    exit($e->getMessage());
}

```

### POST

[](#post)

```
try {
    $response = \Soundcloud::post(
        'tracks/1/comments',
        [
            'body' => 'a new comment'
        ]
    );
} catch (Exception $e) {
    exit($e->getMessage());
}

```

### PUT

[](#put)

```
try {
    $response = \Soundcloud::put(
        'tracks/1',
        [
            'title' => 'my new title'
        ]
    );
} catch (Exception $e) {
    exit($e->getMessage());
}

```

### DELETE

[](#delete)

```
try {
    $response = \Soundcloud::delete('tracks/1');
} catch (Exception $e) {
    exit($e->getMessage());
}

```

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance38

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 77.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~186 days

Recently: every ~268 days

Total

7

Last Release

536d ago

Major Versions

1.2.1 → 2.0.02024-11-22

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/11422029?v=4)[Julien SCHMITT](/maintainers/Noweh)[@noweh](https://github.com/noweh)

---

Top Contributors

[![noweh](https://avatars.githubusercontent.com/u/11422029?v=4)](https://github.com/noweh "noweh (14 commits)")[![Rapkalin](https://avatars.githubusercontent.com/u/69113882?v=4)](https://github.com/Rapkalin "Rapkalin (2 commits)")[![YassineBenaziz](https://avatars.githubusercontent.com/u/7352492?v=4)](https://github.com/YassineBenaziz "YassineBenaziz (2 commits)")

---

Tags

apilaravelphpsoundcloudsoundcloud-apisoundcloud-playerapilaravelsoundcloud

### Embed Badge

![Health badge](/badges/noweh-laravel-soundcloud/health.svg)

```
[![Health](https://phpackages.com/badges/noweh-laravel-soundcloud/health.svg)](https://phpackages.com/packages/noweh-laravel-soundcloud)
```

###  Alternatives

[darkaonline/l5-swagger

OpenApi or Swagger integration to Laravel

2.9k34.0M112](/packages/darkaonline-l5-swagger)[knuckleswtf/scribe

Generate API documentation for humans from your Laravel codebase.✍

2.3k12.2M45](/packages/knuckleswtf-scribe)[nickurt/laravel-postcodeapi

Universal PostcodeApi for Laravel 11.x/12.x/13.x

97221.2k](/packages/nickurt-laravel-postcodeapi)[mozex/anthropic-laravel

Anthropic PHP for Laravel is a supercharged PHP API client that allows you to interact with the Anthropic API

71226.4k1](/packages/mozex-anthropic-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
