Skip to content

PouleR/soundcloud-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Latest Stable Version Latest Unstable Version

SoundCloud API PHP

This is a PHP wrapper for the SoundCloud API.

Requirements

  • PHP >=8.1
  • Symfony HTTP Client

Installation

Install it using Composer:

composer require pouler/soundcloud-api
<?php

require 'vendor/autoload.php';

$curl = new \Symfony\Component\HttpClient\CurlHttpClient();
$client = new PouleR\SoundCloudAPI\SoundCloudClient($curl);

$api = new \PouleR\SoundCloudAPI\SoundCloudAPI($client);
$api->setClientId('client.id');

// Get information about given user
$api->getUser(123456);

// Get information about current usr
$api->setAccessToken('access.token');
$api->getUser();

var_dump($result);