{"id":21081690,"url":"https://github.com/openvoiceos/ovos-media-plugin-spotify","last_synced_at":"2025-12-14T13:44:09.212Z","repository":{"id":174691001,"uuid":"630184739","full_name":"OpenVoiceOS/ovos-media-plugin-spotify","owner":"OpenVoiceOS","description":null,"archived":false,"fork":false,"pushed_at":"2025-11-05T01:21:40.000Z","size":93,"stargazers_count":6,"open_issues_count":4,"forks_count":5,"subscribers_count":5,"default_branch":"dev","last_synced_at":"2025-12-04T11:22:50.285Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/OpenVoiceOS.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["OpenVoiceOS"],"patreon":"openvoiceos","liberapay":"OpenVoiceOS-Foundation","custom":"https://paypal.me/openvoiceos"}},"created_at":"2023-04-19T21:08:24.000Z","updated_at":"2025-11-05T01:21:43.000Z","dependencies_parsed_at":"2024-02-09T15:26:06.131Z","dependency_job_id":"dfbfb020-ed42-4953-8463-a2c295d20f36","html_url":"https://github.com/OpenVoiceOS/ovos-media-plugin-spotify","commit_stats":null,"previous_names":["openvoiceos/ovos-audio-plugin-spotify","openvoiceos/ovos-media-plugin-spotify"],"tags_count":28,"template":false,"template_full_name":null,"purl":"pkg:github/OpenVoiceOS/ovos-media-plugin-spotify","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenVoiceOS%2Fovos-media-plugin-spotify","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenVoiceOS%2Fovos-media-plugin-spotify/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenVoiceOS%2Fovos-media-plugin-spotify/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenVoiceOS%2Fovos-media-plugin-spotify/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OpenVoiceOS","download_url":"https://codeload.github.com/OpenVoiceOS/ovos-media-plugin-spotify/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenVoiceOS%2Fovos-media-plugin-spotify/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27729153,"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-12-14T02:00:11.348Z","response_time":56,"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":[],"created_at":"2024-11-19T20:10:06.553Z","updated_at":"2025-12-14T13:44:09.172Z","avatar_url":"https://github.com/OpenVoiceOS.png","language":"Python","funding_links":["https://github.com/sponsors/OpenVoiceOS","https://patreon.com/openvoiceos","https://liberapay.com/OpenVoiceOS-Foundation","https://paypal.me/openvoiceos"],"categories":[],"sub_categories":[],"readme":"# ovos-media-plugin-spotify\n\nspotify plugin for [ovos-audio](https://github.com/OpenVoiceOS/ovos-audio) and [ovos-media](https://github.com/OpenVoiceOS/ovos-media)\n\nallows OVOS to initiate playback on spotify \n\n\u003e NOTE: [the companion skill](https://github.com/OpenVoiceOS/skill-ovos-spotify) is needed to integrate with voice search\n\n## Install\n\n`pip install ovos-media-plugin-spotify`\n\n## Oauth\n\nCurrently Oauth needs to be performed manually\n\nafter installing the plugin run `ovos-spotify-oauth` on the command line and follow the instructions\n\n```\n$ ovos-spotify-oauth\nThis script creates the token information needed for running spotify\n        with a set of personal developer credentials.\n\n        It requires the user to go to developer.spotify.com and set up a\n        developer account, create an \"Application\" and make sure to whitelist\n        \"https://localhost:8888\".\n\n        After you have done that enter the information when prompted and follow\n        the instructions given.\n        \nYOUR CLIENT ID: xxxxx\nYOUR CLIENT SECRET: xxxxx\nGo to the following URL: https://accounts.spotify.com/authorize?client_id=xxx\u0026response_type=code\u0026redirect_uri=https%3A%2F%2Flocalhost%3A8888\u0026scope=user-library-read+streaming+playlist-read-private+user-top-read+user-read-playback-state\nEnter the URL you were redirected to: https://localhost:8888/?code=.....\nocp_spotify oauth token saved\n```\n\n## Configuration\n\nedit your mycroft.conf with any spotify players you want to expose\n\n\u003e NOTE: If you want to make the OVOS device itself a spotify player, we recommend [spotifyd](https://github.com/Spotifyd/spotifyd).\n\nThe easiest way is to use the provided `ovos-spotify-autoconfigure` command\n\n```bash\n$ ovos-spotify-autoconfigure\nThis script will auto configure ALL spotify devices under your mycroft.conf\n        \n        SPOTIFY PREMIUM is required!\n        \n        If you have not yet authenticated your spotify account, run 'ovos-spotify-oauth' first!\n        \nFound device: OpenVoiceOS-TV\n\nmycroft.conf updated!\n\n# Legacy Audio Service:\n{'backends': {'spotify-OpenVoiceOS-TV': {'active': True,\n                                         'identifier': 'OpenVoiceOS-TV',\n                                         'type': 'ovos_spotify'}}}\n\n# ovos-media Service:\n{'audio_players': {'spotify-OpenVoiceOS-TV': {'active': True,\n                                              'aliases': ['OpenVoiceOS-TV'],\n                                              'identifier': 'OpenVoiceOS-TV',\n                                              'module': 'ovos-media-audio-plugin-spotify'}}}\n```\n\n### ovos-audio\n\n```javascript\n{\n  \"Audio\": {\n    \"backends\": {\n      \"spotify\": {\n        \"type\": \"ovos_spotify\",\n        \"identifier\": \"device_name_in_spotify\",\n        \"active\": true\n      }\n    }\n  }\n}\n```\n\n### ovos-media\n\n\u003e **WARNING**: `ovos-media' has not yet been released, WIP\n\n```javascript\n{\n \"media\": {\n    \"audio_players\": {\n        \"desk_speaker\": {\n            \"module\": \"ovos-media-audio-plugin-spotify\",\n            \n            // this needs to be the name of the device on spotify!\n            \"identifier\": \"Mark2\",\n\n            // users may request specific handlers in the utterance\n            // using these aliases\n            \"aliases\": [\"office spotify\", \"office\", \"desk\", \"workstation\"],\n\n            // deactivate a plugin by setting to false\n            \"active\": true\n        }\n    }\n}\n```\n\n## Python usage\n\nif you don't want to use [the companion skill](https://github.com/OpenVoiceOS/skill-ovos-spotify), you can also write your own integrations\n\n```python\ns = SpotifyClient()\n# pprint(s.query_album(\"hail and kill by manowar\")[1])\n\nfrom ovos_utils.skills.audioservice import ClassicAudioServiceInterface\nfrom ovos_utils.messagebus import FakeBus\n\nbus = FakeBus()\naudio = ClassicAudioServiceInterface(bus)\n\naudio.play(\"spotify:playlist:37i9dQZF1DX08jcQJXDnEQ\")\naudio.play([\"spotify:track:5P2Ghhv0wFYThHfDQaS0g5\",\n            \"spotify:playlist:37i9dQZF1DX08jcQJXDnEQ\"])\ntime.sleep(5)\naudio.pause()\ntime.sleep(5)\n\naudio.resume()\ntime.sleep(5)\n\naudio.next()\ntime.sleep(5)\n\naudio.prev()\ntime.sleep(5)\n\nprint(audio.track_info())\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenvoiceos%2Fovos-media-plugin-spotify","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopenvoiceos%2Fovos-media-plugin-spotify","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenvoiceos%2Fovos-media-plugin-spotify/lists"}