{"id":18753012,"url":"https://github.com/spotify/android-auth","last_synced_at":"2025-04-05T15:08:00.361Z","repository":{"id":12181236,"uuid":"71171131","full_name":"spotify/android-auth","owner":"spotify","description":"Spotify authentication and authorization for Android. Part of the Spotify Android SDK.","archived":false,"fork":false,"pushed_at":"2024-06-03T12:25:26.000Z","size":1161,"stargazers_count":145,"open_issues_count":22,"forks_count":67,"subscribers_count":31,"default_branch":"master","last_synced_at":"2025-03-29T14:08:38.912Z","etag":null,"topics":["android","spotify","spotify-authentication"],"latest_commit_sha":null,"homepage":"https://github.com/spotify/android-sdk","language":"HTML","has_issues":false,"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/spotify.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}},"created_at":"2016-10-17T18:58:26.000Z","updated_at":"2025-01-19T19:24:08.000Z","dependencies_parsed_at":"2024-02-09T16:52:56.076Z","dependency_job_id":null,"html_url":"https://github.com/spotify/android-auth","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spotify%2Fandroid-auth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spotify%2Fandroid-auth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spotify%2Fandroid-auth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spotify%2Fandroid-auth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/spotify","download_url":"https://codeload.github.com/spotify/android-auth/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247353746,"owners_count":20925329,"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":["android","spotify","spotify-authentication"],"created_at":"2024-11-07T17:23:47.070Z","updated_at":"2025-04-05T15:08:00.336Z","avatar_url":"https://github.com/spotify.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Spotify Auth Library\n\n[![Maven Central](https://img.shields.io/maven-central/v/com.spotify.android/auth.svg)](https://search.maven.org/search?q=g:com.spotify.android)\n\n# This repository is now a part of [spotify/android-sdk](https://github.com/spotify/android-sdk). Please post new issues there!\n\nThis library is responsible for authenticating the user and fetching the authorization code/access token\nthat can subsequently be used to play music or in requests to the [Spotify Web API](https://developer.spotify.com/web-api/).\n\n# Breaking changes in Spotify Auth library version 2.0.0\n\nIn this version we replaced use of WebView with [Custom Tabs](https://developer.chrome.com/docs/android/custom-tabs/) since Google and Facebook Login no longer support WebViews for authenticating users.\n\nAs part of this change the library API does not contain `AuthorizationClient#clearCookies` method anymore. Custom Tabs use the cookies from the browser.\n\n# Integrating the library into your project\n\nTo add this library to your project add following dependency to your app `build.gradle` file:\n\n```gradle\nimplementation \"com.spotify.android:auth:\u003cversion\u003e\"\n```\n\nSince April 2021 we're publishing the library on MavenCentral instead of JCenter. Therefore to be able to get the library dependency, you should add MavenCentral into repositories block:\n```gradle\nrepositories {\n    mavenCentral()\n    ...\n}\n```\n\nSince Spotify Auth library version 2.0.0 you also need to provide the scheme and host of the redirect URI that your app is using for authorizing in your app `build.gradle` file.\nBelow is an example of how this looks for [the auth sample project](auth-sample) using `spotify-sdk://auth` redirect URI:\n\n```gradle\n    defaultConfig {\n        manifestPlaceholders = [redirectSchemeName: \"spotify-sdk\", redirectHostName: \"auth\"]\n        ...\n    }\n```\n\nTo learn more see the [Authentication Guide](https://developer.spotify.com/technologies/spotify-android-sdk/android-sdk-authentication-guide/)\nand the [API reference](https://spotify.github.io/android-sdk/auth-lib/docs/index.html).\n\n# Flavors\n\nSince Spotify Auth library version 2.1.0, two versions of the library are provided that differs in\ntheir behaviour if the Spotify application cannot be used to login:\n* `auth` - Opens the web browser to login to Spotify\n* `store` - Redirects to the Android Play store to download the Spotify application\n\n# Sample Code\n\nCheckout [the sample project](auth-sample).\n\n# Contributing\n\nYou are welcome to contribute to this project. Please make sure that:\n* New code is test covered\n* Features and APIs are well documented\n* `./gradlew check` must succeed\n\n## Code of conduct\nThis project adheres to the [Open Code of Conduct][code-of-conduct]. By participating, you are expected to honor this code.\n\n[code-of-conduct]: https://github.com/spotify/code-of-conduct/blob/master/code-of-conduct.md\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspotify%2Fandroid-auth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspotify%2Fandroid-auth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspotify%2Fandroid-auth/lists"}