mrprompt/silex-soundcloud

Silex SoundCloud Provider

dev-master 2016-10-21 15:32 UTC

This package is auto-updated.

Last update: 2024-04-28 07:04:28 UTC


README

Build Status Code Climate Test Coverage Issue Count

Install

composer require mrprompt/silex-soundcloud

Usage

use SilexFriends\SoundCloud\SoundCloud;
use Silex\Application;

$client_id      = getenv('SOUNDCLOUD_CLIENT_ID');
$client_secret  = getenv('SOUNDCLOUD_CLIENT_SECRET');

$app = new Application;
$app->register(new SoundCloud($client_id, $client_secret));

/* @var $url string */
$url = $app['request']->get('url');

/* @var $sound array */
$sound = $app['soundcloud']($url);

var_dump($sound);

Tests

./vendor/bin/phpunit

License

MIT