Skip to content

Google Play Game Services API

by googleapis.com

OAuthHTTPSAnalytics
Open documentation ↗

Overview

The Google Play games service allows developers to enhance games with social leaderboards, achievements, game state, sign-in with Google, and more.

Google Play Game Services is an analytics API from googleapis.com. Requests are authenticated with OAuth. It is served over HTTPS. Its OpenAPI description documents 31 endpoints.

At a glance

Authentication
OAuth
HTTPS
Yes
CORS
Unknown
Category
Analytics
Base URL
https://games.googleapis.com/
Version
v1
Endpoints
31
Spec updated
2023-04-21

Make a first request

Replace the placeholders; the documentation says exactly where credentials go.

cURL
curl -X GET "https://games.googleapis.com/games/v1/achievements" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer YOUR_TOKEN"
JavaScript
const response = await fetch("https://games.googleapis.com/games/v1/achievements", {
  method: "GET",
  headers: {
    "Accept": "application/json",
    "Authorization": "Bearer YOUR_TOKEN",
  },
});
const data = await response.json();
console.log(data);
Python
import requests

response = requests.request(
    "GET",
    "https://games.googleapis.com/games/v1/achievements",
    headers={
    "Accept": "application/json",
    "Authorization": "Bearer YOUR_TOKEN",
    },
    timeout=30,
)
print(response.json())

Endpoints

MethodPathWhat it does
GET/games/v1/achievementsLists all the achievement definitions for your application.
POST/games/v1/achievements/updateMultipleUpdates multiple achievements for the currently authenticated player.
POST/games/v1/achievements/{achievementId}/incrementIncrements the steps of the achievement with the given ID for the currently authenticated player.
POST/games/v1/achievements/{achievementId}/revealSets the state of the achievement with the given ID to `REVEALED` for the currently authenticated player.
POST/games/v1/achievements/{achievementId}/setStepsAtLeastSets the steps for the currently authenticated player towards unlocking an achievement. If the steps parameter is less than the current number of steps that the
POST/games/v1/achievements/{achievementId}/unlockUnlocks this achievement for the currently authenticated player.
POST/games/v1/applications/getEndPointReturns a URL for the requested end point type.
POST/games/v1/applications/playedIndicate that the currently authenticated user is playing your application.
GET/games/v1/applications/{applicationId}Retrieves the metadata of the application with the given ID. If the requested application is not available for the specified `platformType`, the returned respon
GET/games/v1/applications/{applicationId}/verifyVerifies the auth token provided with this request is for the application with the specified ID, and returns the ID of the player it was granted for.
GET/games/v1/eventDefinitionsReturns a list of the event definitions in this application.
GET/games/v1/eventsReturns a list showing the current progress on events in this application for the currently authenticated user.
POST/games/v1/eventsRecords a batch of changes to the number of times events have occurred for the currently authenticated user of this application.
GET/games/v1/leaderboardsLists all the leaderboard metadata for your application.
POST/games/v1/leaderboards/scoresSubmits multiple scores to leaderboards.
GET/games/v1/leaderboards/{leaderboardId}Retrieves the metadata of the leaderboard with the given ID.
POST/games/v1/leaderboards/{leaderboardId}/scoresSubmits a score to the specified leaderboard.
GET/games/v1/leaderboards/{leaderboardId}/scores/{collection}Lists the scores in a leaderboard, starting from the top.
GET/games/v1/leaderboards/{leaderboardId}/window/{collection}Lists the scores in a leaderboard around (and including) a player's score.
GET/games/v1/metagameConfigReturn the metagame configuration data for the calling application.
GET/games/v1/players/me/multipleApplicationPlayerIdsGet the application player ids for the currently authenticated player across all requested games by the same developer as the calling application. This will onl
GET/games/v1/players/me/players/{collection}Get the collection of players for the currently authenticated user.
GET/games/v1/players/me/scopedIdsRetrieves scoped player identifiers for currently authenticated user.
GET/games/v1/players/{playerId}Retrieves the Player resource with the given ID. To retrieve the player for the currently authenticated user, set `playerId` to `me`.
GET/games/v1/players/{playerId}/achievementsLists the progress for all your application's achievements for the currently authenticated player.
GET/games/v1/players/{playerId}/categories/{collection}List play data aggregated per category for the player corresponding to `playerId`.
GET/games/v1/players/{playerId}/leaderboards/{leaderboardId}/scores/{timeSpan}Get high scores, and optionally ranks, in leaderboards for the currently authenticated player. For a specific time span, `leaderboardId` can be set to `ALL` to
GET/games/v1/players/{playerId}/snapshotsRetrieves a list of snapshots created by your application for the player corresponding to the player ID.
GET/games/v1/revisions/checkChecks whether the games client is out of date.
GET/games/v1/snapshots/{snapshotId}Retrieves the metadata for a given snapshot ID.
GET/games/v1/statsReturns engagement and spend statistics in this application for the currently authenticated user.

Questions

Does the Google Play Game Services API need an API key?

Yes. The Google Play Game Services API uses OAuth authentication; the documentation explains how to get credentials.

Does the Google Play Game Services API support HTTPS?

Yes, the Google Play Game Services API is served over HTTPS.

How many endpoints does the Google Play Game Services API have?

Its OpenAPI description lists 31 endpoints in version v1. All of them are shown on this page.

What are alternatives to the Google Play Game Services API?

Other Analytics APIs include Google Play Integrity API, versionhistory.googleapis.com API, Doc Converter, Perspective Comment Analyzer API, Safe Browsing API.

Compare alternatives →

Google Play Integrity API

Analytics

The Play Integrity API helps you check that you're interacting with your genuine app on a genuine Android device powered by Google Play services. The Play Integrity API has replaced SafetyNet Attestation and Android Device Verification.

OAuth1 endpoints

versionhistory.googleapis.com API

Analytics

Version History API - Prod

No auth4 endpoints

Doc Converter

Analytics

This api converts file formats of OpenXml and OpenOffice documents formats to vector files (e.g., svg)

No auth1 endpoints

Perspective Comment Analyzer API

Analytics

The Perspective Comment Analyzer API provides information about the potential impact of a comment on a conversation (e.g. it can provide a score for the "toxicity" of a comment). Users can leverage the "SuggestCommentScore" method to submit corrections to improve Perspective over time. Users can set the "doNotStore" flag to ensure that all submitted comments are automatically deleted after scores are returned.

OAuth2 endpoints

Safe Browsing API

Analytics

Enables client applications to check web resources (most commonly URLs) against Google-generated lists of unsafe web resources. The Safe Browsing APIs are for non-commercial use only. If you need to use APIs to detect malicious URLs for commercial purposes – meaning “for sale or revenue-generating purposes” – please refer to the Web Risk API.

No auth7 endpoints

Web Fonts Developer API

Analytics

The Google Web Fonts Developer API lets you retrieve information about web fonts served by Google.

No auth1 endpoints

Listed from APIs.guru (CC0).