{"id":18985049,"url":"https://github.com/azuracast/php-api-client","last_synced_at":"2025-10-28T13:11:02.916Z","repository":{"id":33509331,"uuid":"159062546","full_name":"AzuraCast/php-api-client","owner":"AzuraCast","description":"An API client library for the AzuraCast API","archived":false,"fork":false,"pushed_at":"2025-01-27T22:53:18.000Z","size":705,"stargazers_count":30,"open_issues_count":13,"forks_count":20,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-09-15T12:40:57.646Z","etag":null,"topics":["api","azuracast","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AzuraCast.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"AzuraCast","open_collective":"azuracast","patreon":"AzuraCast","ko_fi":"SilverEagle","liberapay":"BusterNeece","custom":["https://donate.azuracast.com/"]}},"created_at":"2018-11-25T18:37:23.000Z","updated_at":"2025-08-25T16:44:46.000Z","dependencies_parsed_at":"2023-01-15T01:13:55.477Z","dependency_job_id":"da5d5c0d-c5a1-4e0e-bb88-935bb096223e","html_url":"https://github.com/AzuraCast/php-api-client","commit_stats":{"total_commits":78,"total_committers":6,"mean_commits":13.0,"dds":0.5641025641025641,"last_synced_commit":"524d467b8df462d8e7c5f04c67802a2459c27576"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/AzuraCast/php-api-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AzuraCast%2Fphp-api-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AzuraCast%2Fphp-api-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AzuraCast%2Fphp-api-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AzuraCast%2Fphp-api-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AzuraCast","download_url":"https://codeload.github.com/AzuraCast/php-api-client/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AzuraCast%2Fphp-api-client/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278296081,"owners_count":25963432,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","azuracast","php"],"created_at":"2024-11-08T16:24:29.777Z","updated_at":"2025-10-04T09:59:56.421Z","avatar_url":"https://github.com/AzuraCast.png","language":"PHP","funding_links":["https://github.com/sponsors/AzuraCast","https://opencollective.com/azuracast","https://patreon.com/AzuraCast","https://ko-fi.com/SilverEagle","https://liberapay.com/BusterNeece","https://donate.azuracast.com/"],"categories":[],"sub_categories":[],"readme":"This PHP library provides an API client for the [AzuraCast](https://github.com/AzuraCast/AzuraCast) JSON API.\n\n# Installation\n\nIt is highly recommended to use the [Composer]() package manager to install this client by running this command:\n\n```bash\ncomposer require azuracast/php-api-client\n```\n\n# Usage\n\n```php\n\u003c?php\n\nrequire __DIR__ . '/vendor/autoload.php';\n\n$api = \\AzuraCast\\Api\\Client::create(\n\t'\u003cIP-Address | Host\u003e',\n\t'\u003cAPI Key\u003e'\n);\n\n$nowPlaying = $api-\u003enowPlaying();\n\necho $nowPlaying-\u003egetCurrentSong()-\u003egetSong()-\u003egetTitle();\n```\n\n# Available Endpoints\n\n### Now Playing\n`GET` `/nowplaying`\n```\n$api-\u003enowPlaying();\n```\n\n`GET` `/nowplaying/{station_id}`\n```\n$api-\u003estation($station_id)-\u003enowPlaying();\n```\n\n### Stations: General\n`GET` `/stations`\n```\n$api-\u003estations();\n```\n\n`GET` `/station/{station_id}`\n```\n$api-\u003estation($stationId)-\u003eget();\n```\n\n### Stations: Song Requests\n`GET` `/station/{station_id}/requests`\n```\n$api-\u003estation($stationId)-\u003erequests()-\u003elist();\n```\n\n`POST` `/station/{station_id}/request/{request_id}`\n```\n$api-\u003estation($stationId)-\u003erequests()-\u003esubmit($uniqueId);\n```\n\n### Stations: Service Control\n`GET` `/station/{station_id}/status`\n```\n$api-\u003estation($stationId)-\u003estatus();\n```\n\n`POST` `/station/{station_id}/restart`\n```\n$api-\u003estation($stationId)-\u003erestart();\n```\n\n`POST` `/station/{station_id}/frontend/{action}`\n```\n$api-\u003estation($stationId)-\u003efrontend($action);\n```\n\n`POST` `/station/{station_id}/backend/{action}`\n```\n$api-\u003estation($stationId)-\u003ebackend($action);\n```\n\n### Stations: History\n`GET` `/station/{station_id}/history`\n```\n$api-\u003estation($stationId)-\u003ehistory(?\\DateTime $start = null, ?\\DateTime $end = null);\n```\n\n### Stations: Listeners\n`GET` `/station/{station_id}/listeners`\n```\n$api-\u003estation($stationId)-\u003elisteners();\n```\n\n### Stations: Media\n`GET` `/station/{station_id}/art/{media_id}`\n```\n$api-\u003estation($stationId)-\u003emedia()-\u003eart($uniqueId);\n```\n\n`GET` `/station/{station_id}/files`\n```\n$api-\u003estation($stationId)-\u003emedia()-\u003elist();\n```\n\n`POST` `/station/{station_id}/files`\n```\n$api-\u003estation($stationId)-\u003emedia()-\u003eupload(UploadFileDto $uploadFile);\n```\n\n### Stations: Mount Points\n`GET` `/station/{station_id}/mounts`\n```\n$api-\u003estation($stationId)-\u003emounts();\n```\n\n### Station: Streamers/DJs\n`GET` `/station/{station_id}/streamers`\n```\n$api-\u003estation($stationId)-\u003estreamers()-\u003elist();\n```\n\n`GET` `/station/{station_id}/streamer/{id}`\n```\n$api-\u003estation($stationId)-\u003estreamers()-\u003eget(int $streamerId);\n```\n\n`POST` `/station/{station_id}/streamers`\n```\n$api-\u003estation($stationId)-\u003estreamers()-\u003ecreate(\n\tstring $username,\n\tstring $password,\n\tstring $displayName,\n\tstring $comments,\n\tbool $isActive\n);\n```\n\n`PUT` `/station/{station_id}/streamer/{id}`\n```\n$api-\u003estation($stationId)-\u003estreamers()-\u003eupdate(\n\tint $streamerId,\n\tstring $username,\n\tstring $password,\n\tstring $displayName,\n\tstring $comments,\n\tbool $isActive\n);\n```\n\n`DELETE` `/station/{station_id}/streamer/{id}`\n```\n$api-\u003estation($stationId)-\u003estreamers()-\u003edelete($streamerId);\n```\n\n### Administration: Custom Fields\n`GET` `/admin/custom_fields`\n```\n$api-\u003eadmin()-\u003ecustomFields()-\u003elist();\n```\n\n`POST` `/admin/custom_fields`\n```\n$api-\u003eadmin()-\u003ecustomFields()-\u003eget(int $customFieldId);\n```\n\n`GET` `/admin/custom_fields/{id}`\n```\n$api-\u003eadmin()-\u003ecustomFields()-\u003ecreate(string $name, string $shortName);\n```\n\n`PUT` `/admin/custom_fields/{id}`\n```\n$api-\u003eadmin()-\u003ecustomFields()-\u003eupdate(int $customFieldId, string $name, string $shortName);\n```\n\n`DELETE` `/admin/custom_fields/{id}`\n```\n$api-\u003eadmin()-\u003ecustomFields()-\u003edelete(int $customFieldId);\n```\n\n### Administration: Users\n`GET` `/admin/users`\n```\n$api-\u003eadmin()-\u003eusers()-\u003elist();\n```\n\n`GET` `/admin/user/{id}`\n```\n$api-\u003eadmin()-\u003eusers()-\u003eget(int $userId);\n```\n\n`POST` `/admin/users`\n```\n$api-\u003eadmin()-\u003eusers()-\u003ecreate(\n\tstring $email,\n\tstring $authPassword,\n\tstring $name,\n\tstring $timezone,\n\tstring $locale,\n\tstring $theme,\n\tarray $roles,\n\tarray $apiKeys\n);\n```\n\n\n`PUT` `/admin/user/{id}`\n```\n$api-\u003eadmin()-\u003eusers()-\u003eupdate(\n\tint $userId,\n\tstring $email,\n\tstring $authPassword,\n\tstring $name,\n\tstring $timezone,\n\tstring $locale,\n\tstring $theme,\n\tarray $roles,\n\tarray $apiKeys\n);\n```\n\n`DELETE` `/admin/user/{id}`\n```\n$api-\u003eadmin()-\u003eusers()-\u003edelete(int $userId);\n```\n\n### Administration: Roles\n`GET` `/admin/permissions`\n```\n$api-\u003eadmin()-\u003epermissions();\n```\n\n`GET` `/admin/roles`\n```\n$api-\u003eadmin()-\u003eroles()-\u003elist();\n```\n\n`GET` `/admin/role/{id}`\n```\n$api-\u003eadmin()-\u003eroles()-\u003eget(int $roleId);\n```\n\n`POST` `/admin/roles`\n```\n$api-\u003eadmin()-\u003eroles()-\u003ecreate(\n\tstring $name,\n\tstring[] $permissionsGlobal,\n\tstring[] $permissionsStation\n);\n```\n\n`PUT` `/admin/role/{id}`\n```\n$api-\u003eadmin()-\u003eroles()-\u003eupdate(\n\tint $roleId\n\tstring $name\n\tstring[] $permissionsGlobal\n\tstring[] $permissionsStation\n);\n```\n\n`DELETE` `/admin/role/{id}`\n```\n$api-\u003eadmin()-\u003eroles()-\u003edelete(int $roleId);\n```\n\n### Administration: Settings\n`GET` `/admin/settings`\n```\n$api-\u003eadmin()-\u003esettings()-\u003elist();\n```\n\n`PUT` `/admin/settings`\n```\n$api-\u003eadmin()-\u003esettings()-\u003eupdate(\n\tstring $baseUrl,\n\tstring $instanceName,\n\tstring $timezone,\n\tbool $preferBrowserUrl,\n\tbool $useRadioProxy,\n\tint $historyKeepDays,\n\tbool $alwaysUseSsl,\n\tstring $apiAccessControl,\n\tstring $analytics,\n\tbool $centralUpdatesChannel,\n\tstring $publicTheme,\n\tbool $hideAlbumArt,\n\tstring $homepageRedirectUrl,\n\tstring $defaultAlbumArtUrl,\n\tbool $hideProductName,\n\tstring $customCssPublic,\n\tstring $customJsPublic,\n\tstring $customCssInternal\n);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fazuracast%2Fphp-api-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fazuracast%2Fphp-api-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fazuracast%2Fphp-api-client/lists"}