blob: e2459b6e5d9432fbaaf4ae9c2992705292680397 [file] [log] [blame]
John Asmuth614db982014-04-24 15:46:26 -04001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="games_v1.html">Google Play Game Services API</a> . <a href="games_v1.applications.html">applications</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070078 <code><a href="#get">get(applicationId, language=None, consistencyToken=None, platformType=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -040079<p class="firstline">Retrieves the metadata of the application with the given ID. If the requested application is not available for the specified platformType, the returned response will not include any instance data.</p>
80<p class="toc_element">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070081 <code><a href="#played">played(consistencyToken=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -040082<p class="firstline">Indicate that the the currently authenticated user is playing your application.</p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080083<p class="toc_element">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070084 <code><a href="#verify">verify(applicationId, consistencyToken=None)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080085<p class="firstline">Verifies 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.</p>
John Asmuth614db982014-04-24 15:46:26 -040086<h3>Method Details</h3>
87<div class="method">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070088 <code class="details" id="get">get(applicationId, language=None, consistencyToken=None, platformType=None)</code>
John Asmuth614db982014-04-24 15:46:26 -040089 <pre>Retrieves the metadata of the application with the given ID. If the requested application is not available for the specified platformType, the returned response will not include any instance data.
90
91Args:
Craig Citroe633be12015-03-02 13:40:36 -080092 applicationId: string, The application ID from the Google Play developer console. (required)
John Asmuth614db982014-04-24 15:46:26 -040093 language: string, The preferred language to use for strings returned by this method.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070094 consistencyToken: string, The last-seen mutation timestamp.
John Asmuth614db982014-04-24 15:46:26 -040095 platformType: string, Restrict application details returned to the specific platform.
96 Allowed values
97 ANDROID - Retrieve applications that can be played on Android.
98 IOS - Retrieve applications that can be played on iOS.
99 WEB_APP - Retrieve applications that can be played on desktop web.
100
101Returns:
102 An object of the form:
103
104 { # This is a JSON template for the Application resource.
105 "category": { # This is a JSON template for an application category object. # The category of the application.
106 "kind": "games#applicationCategory", # Uniquely identifies the type of this resource. Value is always the fixed string games#applicationCategory.
107 "primary": "A String", # The primary category.
108 "secondary": "A String", # The secondary category.
109 },
110 "kind": "games#application", # Uniquely identifies the type of this resource. Value is always the fixed string games#application.
111 "description": "A String", # The description of the application.
112 "author": "A String", # The author of the application.
113 "lastUpdatedTimestamp": "A String", # The last updated timestamp of the application.
Craig Citro0e5b9bf2014-10-15 10:26:14 -0700114 "themeColor": "A String", # A hint to the client UI for what color to use as an app-themed color. The color is given as an RGB triplet (e.g. "E0E0E0").
John Asmuth614db982014-04-24 15:46:26 -0400115 "name": "A String", # The name of the application.
116 "instances": [ # The instances of the application.
117 { # This is a JSON template for the Instance resource.
118 "kind": "games#instance", # Uniquely identifies the type of this resource. Value is always the fixed string games#instance.
119 "acquisitionUri": "A String", # URI which shows where a user can acquire this instance.
120 "name": "A String", # Localized display name.
121 "turnBasedPlay": True or False, # Flag to show if this game instance supports turn based play.
122 "webInstance": { # This is a JSON template for the Web details resource. # Platform dependent details for Web.
123 "kind": "games#instanceWebDetails", # Uniquely identifies the type of this resource. Value is always the fixed string games#instanceWebDetails.
124 "launchUrl": "A String", # Launch URL for the game.
125 "preferred": True or False, # Indicates that this instance is the default for new installations.
126 },
127 "androidInstance": { # This is a JSON template for the Android instance details resource. # Platform dependent details for Android.
128 "kind": "games#instanceAndroidDetails", # Uniquely identifies the type of this resource. Value is always the fixed string games#instanceAndroidDetails.
129 "enablePiracyCheck": True or False, # Flag indicating whether the anti-piracy check is enabled.
130 "packageName": "A String", # Android package name which maps to Google Play URL.
131 "preferred": True or False, # Indicates that this instance is the default for new installations.
132 },
133 "iosInstance": { # This is a JSON template for the iOS details resource. # Platform dependent details for iOS.
134 "kind": "games#instanceIosDetails", # Uniquely identifies the type of this resource. Value is always the fixed string games#instanceIosDetails.
135 "supportIphone": True or False, # Flag to indicate if this instance supports iPhone.
136 "preferredForIpad": True or False, # Indicates that this instance is the default for new installations on iPad devices.
137 "itunesAppId": "A String", # iTunes App ID.
138 "bundleIdentifier": "A String", # Bundle identifier.
139 "supportIpad": True or False, # Flag to indicate if this instance supports iPad.
140 "preferredForIphone": True or False, # Indicates that this instance is the default for new installations on iPhone devices.
141 },
142 "platformType": "A String", # The platform type.
143 # Possible values are:
144 # - "ANDROID" - Instance is for Android.
145 # - "IOS" - Instance is for iOS
146 # - "WEB_APP" - Instance is for Web App.
147 "realtimePlay": True or False, # Flag to show if this game instance supports realtime play.
148 },
149 ],
150 "achievement_count": 42, # The number of achievements visible to the currently authenticated player.
151 "leaderboard_count": 42, # The number of leaderboards visible to the currently authenticated player.
John Asmuth614db982014-04-24 15:46:26 -0400152 "assets": [ # The assets of the application.
153 { # This is a JSON template for an image asset object.
154 "url": "A String", # The URL of the asset.
155 "width": 42, # The width of the asset.
156 "kind": "games#imageAsset", # Uniquely identifies the type of this resource. Value is always the fixed string games#imageAsset.
157 "name": "A String", # The name of the asset.
158 "height": 42, # The height of the asset.
159 },
160 ],
Craig Citro065b5302014-08-14 00:47:23 -0700161 "id": "A String", # The ID of the application.
162 "enabledFeatures": [ # A list of features that have been enabled for the application.
163 # Possible values are:
164 # - "SNAPSHOTS" - Snapshots has been enabled
165 "A String",
166 ],
John Asmuth614db982014-04-24 15:46:26 -0400167 }</pre>
168</div>
169
170<div class="method">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700171 <code class="details" id="played">played(consistencyToken=None)</code>
John Asmuth614db982014-04-24 15:46:26 -0400172 <pre>Indicate that the the currently authenticated user is playing your application.
173
174Args:
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700175 consistencyToken: string, The last-seen mutation timestamp.
John Asmuth614db982014-04-24 15:46:26 -0400176</pre>
177</div>
178
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800179<div class="method">
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700180 <code class="details" id="verify">verify(applicationId, consistencyToken=None)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800181 <pre>Verifies 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.
182
183Args:
184 applicationId: string, The application ID from the Google Play developer console. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700185 consistencyToken: string, The last-seen mutation timestamp.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800186
187Returns:
188 An object of the form:
189
190 { # This is a JSON template for a third party application verification response resource.
191 "player_id": "A String", # The ID of the player that was issued the auth token used in this request.
192 "kind": "games#applicationVerifyResponse", # Uniquely identifies the type of this resource. Value is always the fixed string games#applicationVerifyResponse.
Jon Wayne Parrott0a471d32016-05-19 10:54:38 -0700193 "alternate_player_id": "A String", # An alternate ID that was once used for the player that was issued the auth token used in this request. (This field is not normally populated.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800194 }</pre>
195</div>
196
John Asmuth614db982014-04-24 15:46:26 -0400197</body></html>