uk.co.caprica:gplaymusic

A library to manage the Google Play Music service through a java application.

License

License

GroupId

GroupId

uk.co.caprica
ArtifactId

ArtifactId

gplaymusic
Last Version

Last Version

0.3.9pre1
Release Date

Release Date

Type

Type

jar
Description

Description

uk.co.caprica:gplaymusic
A library to manage the Google Play Music service through a java application.
Project URL

Project URL

https://github.com/caprica/gplaymusic
Source Code Management

Source Code Management

https://github.com/caprica/gplaymusic

Download gplaymusic

How to add to project

<!-- https://jarcasting.com/artifacts/uk.co.caprica/gplaymusic/ -->
<dependency>
    <groupId>uk.co.caprica</groupId>
    <artifactId>gplaymusic</artifactId>
    <version>0.3.9pre1</version>
</dependency>
// https://jarcasting.com/artifacts/uk.co.caprica/gplaymusic/
implementation 'uk.co.caprica:gplaymusic:0.3.9pre1'
// https://jarcasting.com/artifacts/uk.co.caprica/gplaymusic/
implementation ("uk.co.caprica:gplaymusic:0.3.9pre1")
'uk.co.caprica:gplaymusic:jar:0.3.9pre1'
<dependency org="uk.co.caprica" name="gplaymusic" rev="0.3.9pre1">
  <artifact name="gplaymusic" type="jar" />
</dependency>
@Grapes(
@Grab(group='uk.co.caprica', module='gplaymusic', version='0.3.9pre1')
)
libraryDependencies += "uk.co.caprica" % "gplaymusic" % "0.3.9pre1"
[uk.co.caprica/gplaymusic "0.3.9pre1"]

Dependencies

compile (6)

Group / Artifact Type Version
com.google.code.gson : gson jar 2.8.5
io.github.svarzee : gpsoauth-java jar 0.9.1
com.squareup.retrofit2 : retrofit jar 2.5.0
com.squareup.retrofit2 : converter-gson jar 2.5.0
javax.validation : validation-api jar 1.1.0.Final
io.gsonfire : gson-fire jar 1.8.3

test (2)

Group / Artifact Type Version
org.apache.tika : tika-core jar 1.20
junit : junit jar 4.12

Project Modules

There are no modules declared in this project.

Unofficial GPlayMusic API in JAVA

CircleCI CircleCI
GitHub release

This project is a fork of FelixGail/gplaymusic that fixes various outstanding issues, in particular token authentication failures are fixed, as is stream quality selection.

This version is confirmed working with a Java 8 runtime environment, it will not presently work with Java 11 or Java 13 due to some platform API incompatibilities.

If you want to use this fork instead of the original, use the following dependency:

<dependency>
    <groupId>uk.co.caprica</groupId>
    <artifactId>gplaymusic</artifactId>
    <version>0.3.9pre1</version>
</dependency>

Original README:

This library poses as a client for the GooglePlay app. It can search for songs/artists/albums, modify and create playlists and stations and even download tracks. For most activities an active subscription to GooglePlay All Access is needed.

This project is neither supported nor endorsed by Google.

This API should not be considered stable until version 1.0.0

Installation

Maven:

To use this library, simply add the following lines to your pom.xml:

Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

<dependency>
    <groupId>com.github.felixgail</groupId>
    <artifactId>gplaymusic</artifactId>
    <version>0.3.6</version>
</dependency>

Otherwise download the latest version from the releases page.

Getting Started

Collecting your credentials:

To use the api you will need to provide the following information:

  • USERNAME: The email or username to your google account.
  • PASSWORD: The password to your google account or, if you are using 2-factor-authorization, an app password created here.
  • ANDROID_ID: The IMEI of an android device that had GooglePlayMusic installed.

Provided information will never be saved by this project.

Fetching an authorization token:
AuthToken authToken = TokenProvider.provideToken(USERNAME,
                                      PASSWORD, ANDROID_ID);
Creating a new API instance:
GPlayMusic api = new GPlayMusic.Builder()
                  .setAuthToken(authToken)
                  .build();

And you are ready to go.
A full documentation should come sometime in the future. For now use the Javadoc to help yourself. It can be found here.

Feel free to create an issue if you have questions or problems.

Attribution

Special thanks to gmusicapi project by Simon Webers. I started this project as a port for this great library.

Versions

Version
0.3.9pre1