{"id":18744684,"url":"https://github.com/neutonfoo/go-spotifycli","last_synced_at":"2025-09-09T18:10:33.963Z","repository":{"id":113098427,"uuid":"266498018","full_name":"neutonfoo/Go-SpotifyCLI","owner":"neutonfoo","description":"An experimental SpotifyCLI written in Go.","archived":false,"fork":false,"pushed_at":"2020-05-24T11:37:52.000Z","size":6166,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-05-20T07:11:25.204Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/neutonfoo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2020-05-24T08:15:08.000Z","updated_at":"2020-10-04T16:37:11.000Z","dependencies_parsed_at":null,"dependency_job_id":"2d274429-5d87-48c1-ab9e-404a16718ba6","html_url":"https://github.com/neutonfoo/Go-SpotifyCLI","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/neutonfoo/Go-SpotifyCLI","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neutonfoo%2FGo-SpotifyCLI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neutonfoo%2FGo-SpotifyCLI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neutonfoo%2FGo-SpotifyCLI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neutonfoo%2FGo-SpotifyCLI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/neutonfoo","download_url":"https://codeload.github.com/neutonfoo/Go-SpotifyCLI/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neutonfoo%2FGo-SpotifyCLI/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261469314,"owners_count":23163065,"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","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-07T16:15:39.081Z","updated_at":"2025-06-23T11:33:35.471Z","avatar_url":"https://github.com/neutonfoo.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Go-SpotifyCLI\n\nI made this for fun and to practice using Go. It isn't meant for serious use. Album Art is shown through imgcat and will only work with iTerm2.\n\n## Dependencies\n\nInstall dependencies with `go get -d ./`\n\n## Install Instruction\n\nA Spotify application has to be created on the Spotify Developers website. Export the client id and client key as environmental variables (or paste them into the `clientID` and `secretKey` respective if you are building a binary).\n\nAdditionally, the redirect URL\n\n## Usage\n\nYou must first generate a JSON containing the oAuth token (saved into home directly by default) by using the `-login` flag. Similarly, use this flag to force generate a new oAuth token should the refresh token expire. This will start a web server on port 8080 to receive the oAuth callback.\n\n`go run play.go -login`\n\nThen run `go run play.go search query`. This will perform a track search via the Spotify API with the query `search query` and play the first result.\n\nTo, instead, select from a list of returned results use the `-l` flag. It will list the top 10 results and prompt for which one to play.\n\nDuring testing, I ran into issues where the song would not start due to there being no active speaker. In order to set the active player, use the `-p` flag. Selection of the player will be similar to the `-l` flag.\n\n## Screenshots\n\nI used `go build` to generate a binary (named `play`) and placed it in my `~/bin` folder. If you want to do this, don't forget to add `$HOME/bin` into your path as it's not included on macOS by default. You may also need to hardcode your client id and secret key.\n\n\u003cimg src=\"screenshot.png\" alt=\"Go-SpotifyCLI Screenshot\" width=\"350\"/\u003e\n\n\u003cbr\u003e\n\n\u003cimg src=\"screenshot-2.png\" alt=\"Go-SpotifyCLI Screenshot 2\" width=\"350\"/\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneutonfoo%2Fgo-spotifycli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fneutonfoo%2Fgo-spotifycli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneutonfoo%2Fgo-spotifycli/lists"}