How can I reset achievements from Google Game Services?

user2391981 picture user2391981 · May 19, 2013 · Viewed 21.5k times · Source

I'm testing my game using Google's new Games Services, and I'd like to reset my account's achievements for testing.

I've found that you can reset achievements using google's APIs (https://developers.google.com/games/services/management/api/#Achievements) and I'm using the OAuth 2.0 playground to send the POST request, but it's not working :(

Specifically, I'm a sending POST request for "https://www.googleapis.com/games/v1management/achievements/reset" as detailed in that link.

AND, when I go to code.google com and check my Services, all the Play services are "ON".

Here is the output. How can I reset my achievements for testing? Am I even close? Apparently my "access is not configured" How do I do that? What was the point of the whole first 2 steps of the OAuth2.0 playground if not to grant my access?

HTTP/1.1 403 Forbidden
Content-length: 205
X-xss-protection: 1; mode=block
X-content-type-options: nosniff
X-google-cache-control: remote-fetch
-content-encoding: gzip
Server: GSE
Reason: Forbidden
Via: HTTP/1.1 GWA
Cache-control: private, max-age=0
Date: Sun, 19 May 2013 04:11:38 GMT
X-frame-options: SAMEORIGIN
Content-type: application/json; charset=UTF-8
Expires: Sun, 19 May 2013 04:11:38 GMT
{
 "error": {
  "errors": [
   {
    "domain": "usageLimits",
    "reason": "accessNotConfigured",
    "message": "Access Not Configured"
   }
  ],
  "code": 403,
  "message": "Access Not Configured"
 }
}

Answer

m1h4 picture m1h4 · Sep 27, 2013

This is how I got it to work:

  1. Open the Google Play Developer Console, go to Linked Apps under Game Services and click Link another App -> Web, for the URL use https://developers.google.com/oauthplayground and complete the setup of this linked app. Make sure the same URL is listed as an authorized redirect URI.

  2. Go to https://developers.google.com/oauthplayground and click on the gears icon in top right, select Use your own OAuth credentials, and copy the Client ID and Client secret for your Web app from https://code.google.com/apis/console.

  3. For the Scope in OAuth Playground's Step 1 use https://www.googleapis.com/auth/games, which is found under Google Play Game Services API.

  4. Do a POST to https://www.googleapis.com/games/v1management/achievements/reset or https://www.googleapis.com/games/v1management/achievements/resetAllForAllPlayers or whatever, leave all other options as is.

  5. Profit :)

Note:

At first I was doing step 2. after step 3. and it gave me the 403