blob: f0307d19627f4df79af2c8cfa0b40bc33b1fc9f9 [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.rooms.html">rooms</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#create">create(body, language=None)</a></code></p>
79<p class="firstline">Create a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
80<p class="toc_element">
81 <code><a href="#decline">decline(roomId, language=None)</a></code></p>
82<p class="firstline">Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
83<p class="toc_element">
84 <code><a href="#dismiss">dismiss(roomId)</a></code></p>
85<p class="firstline">Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
86<p class="toc_element">
87 <code><a href="#get">get(roomId, language=None)</a></code></p>
88<p class="firstline">Get the data for a room.</p>
89<p class="toc_element">
90 <code><a href="#join">join(roomId, body, language=None)</a></code></p>
91<p class="firstline">Join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
92<p class="toc_element">
93 <code><a href="#leave">leave(roomId, body, language=None)</a></code></p>
94<p class="firstline">Leave a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
95<p class="toc_element">
96 <code><a href="#list">list(pageToken=None, language=None, maxResults=None)</a></code></p>
97<p class="firstline">Returns invitations to join rooms.</p>
98<p class="toc_element">
99 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
100<p class="firstline">Retrieves the next page of results.</p>
101<p class="toc_element">
102 <code><a href="#reportStatus">reportStatus(roomId, body, language=None)</a></code></p>
103<p class="firstline">Updates sent by a client reporting the status of peers in a room. For internal use by the Games SDK only. Calling this method directly is unsupported.</p>
104<h3>Method Details</h3>
105<div class="method">
106 <code class="details" id="create">create(body, language=None)</code>
107 <pre>Create a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
108
109Args:
110 body: object, The request body. (required)
111 The object takes the form of:
112
113{ # This is a JSON template for a room creation request.
114 "kind": "games#roomCreateRequest", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomCreateRequest.
115 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
116 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
117 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
118 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
119 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
120 },
121 "invitedPlayerIds": [ # The player IDs to invite to the room.
122 "A String",
123 ],
124 "variant": 42, # The variant / mode of the application to be played. This can be any integer value, or left blank. You should use a small number of variants to keep the auto-matching pool as large as possible.
125 "capabilities": [ # The capabilities that this client supports for realtime communication.
126 "A String",
127 ],
128 "networkDiagnostics": { # This is a JSON template for network diagnostics reported for a client. # Network diagnostics for the client creating the room.
John Asmuth614db982014-04-24 15:46:26 -0400129 "kind": "games#networkDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#networkDiagnostics.
Craig Citro065b5302014-08-14 00:47:23 -0700130 "iosNetworkType": 42, # iOS network type as defined in Reachability.h.
131 "networkOperatorCode": "A String", # The MCC+MNC code for the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperator() On iOS, see: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html
John Asmuth614db982014-04-24 15:46:26 -0400132 "androidNetworkSubtype": 42, # The Android network subtype.
Craig Citro065b5302014-08-14 00:47:23 -0700133 "networkOperatorName": "A String", # The name of the carrier of the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperatorName() On iOS: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html#//apple_ref/occ/instp/CTCarrier/carrierName
134 "registrationLatencyMillis": 42, # The amount of time in milliseconds it took for the client to establish a connection with the XMPP server.
John Asmuth614db982014-04-24 15:46:26 -0400135 "androidNetworkType": 42, # The Android network type.
136 },
137 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the player creating the room.
138 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
139 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
140 },
141 "requestId": "A String", # A randomly generated numeric ID. This number is used at the server to ensure that the request is handled correctly across retries.
142 }
143
144 language: string, The preferred language to use for strings returned by this method.
145
146Returns:
147 An object of the form:
148
149 { # This is a JSON template for a room resource object.
150 "status": "A String", # The status of the room.
151 # Possible values are:
152 # - "ROOM_INVITING" - One or more players have been invited and not responded.
153 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
154 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
155 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
156 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
157 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
158 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
159 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
160 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
161 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
162 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
163 },
164 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
165 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
166 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
167 "participantId": "A String", # The ID of the participant that modified the room.
168 },
169 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
170 "roomId": "A String", # Globally unique ID for a room.
171 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
172 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
173 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
174 },
175 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
176 { # This is a JSON template for a participant in a room.
177 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
178 "status": "A String", # The status of the participant with respect to the room.
179 # Possible values are:
180 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
181 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
182 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
183 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
184 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
185 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
186 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
187 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
188 "displayName": "A String", # The name to display for the anonymous player.
189 },
190 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
191 # Possible values are:
192 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
193 # - "GAME_LEFT" - The game chose to remove the player from the room.
194 # - "ABANDONED" - The player switched to another application and abandoned the room.
195 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
196 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
197 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
198 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
199 "capabilities": [ # The capabilities which can be used when communicating with this participant.
200 "A String",
201 ],
202 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800203 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400204 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
205 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700206 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
207 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
208 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400209 },
Craig Citro065b5302014-08-14 00:47:23 -0700210 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400211 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
212 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
213 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
214 },
215 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800216 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700217 "title": "A String", # The player's title rewarded for their game activities.
218 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
219 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
220 "currentExperiencePoints": "A String", # The current number of experience points for the player.
221 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
222 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
223 "maxExperiencePoints": "A String", # The maximum experience points for this level.
224 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
225 "minExperiencePoints": "A String", # The minimum experience points for this level.
226 "level": 42, # The level for the user.
227 },
228 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
229 "maxExperiencePoints": "A String", # The maximum experience points for this level.
230 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
231 "minExperiencePoints": "A String", # The minimum experience points for this level.
232 "level": 42, # The level for the user.
233 },
234 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800235 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400236 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
237 },
238 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
239 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
240 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
241 },
242 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
243 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
244 },
245 ],
246 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
247 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
248 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
249 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
250 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
251 "participantId": "A String", # The ID of the participant that modified the room.
252 },
253 "applicationId": "A String", # The ID of the application being played.
254 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
255 }</pre>
256</div>
257
258<div class="method">
259 <code class="details" id="decline">decline(roomId, language=None)</code>
260 <pre>Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
261
262Args:
263 roomId: string, The ID of the room. (required)
264 language: string, The preferred language to use for strings returned by this method.
265
266Returns:
267 An object of the form:
268
269 { # This is a JSON template for a room resource object.
270 "status": "A String", # The status of the room.
271 # Possible values are:
272 # - "ROOM_INVITING" - One or more players have been invited and not responded.
273 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
274 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
275 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
276 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
277 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
278 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
279 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
280 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
281 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
282 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
283 },
284 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
285 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
286 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
287 "participantId": "A String", # The ID of the participant that modified the room.
288 },
289 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
290 "roomId": "A String", # Globally unique ID for a room.
291 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
292 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
293 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
294 },
295 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
296 { # This is a JSON template for a participant in a room.
297 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
298 "status": "A String", # The status of the participant with respect to the room.
299 # Possible values are:
300 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
301 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
302 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
303 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
304 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
305 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
306 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
307 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
308 "displayName": "A String", # The name to display for the anonymous player.
309 },
310 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
311 # Possible values are:
312 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
313 # - "GAME_LEFT" - The game chose to remove the player from the room.
314 # - "ABANDONED" - The player switched to another application and abandoned the room.
315 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
316 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
317 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
318 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
319 "capabilities": [ # The capabilities which can be used when communicating with this participant.
320 "A String",
321 ],
322 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800323 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400324 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
325 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700326 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
327 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
328 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400329 },
Craig Citro065b5302014-08-14 00:47:23 -0700330 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400331 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
332 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
333 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
334 },
335 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800336 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700337 "title": "A String", # The player's title rewarded for their game activities.
338 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
339 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
340 "currentExperiencePoints": "A String", # The current number of experience points for the player.
341 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
342 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
343 "maxExperiencePoints": "A String", # The maximum experience points for this level.
344 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
345 "minExperiencePoints": "A String", # The minimum experience points for this level.
346 "level": 42, # The level for the user.
347 },
348 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
349 "maxExperiencePoints": "A String", # The maximum experience points for this level.
350 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
351 "minExperiencePoints": "A String", # The minimum experience points for this level.
352 "level": 42, # The level for the user.
353 },
354 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800355 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400356 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
357 },
358 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
359 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
360 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
361 },
362 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
363 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
364 },
365 ],
366 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
367 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
368 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
369 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
370 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
371 "participantId": "A String", # The ID of the participant that modified the room.
372 },
373 "applicationId": "A String", # The ID of the application being played.
374 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
375 }</pre>
376</div>
377
378<div class="method">
379 <code class="details" id="dismiss">dismiss(roomId)</code>
380 <pre>Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
381
382Args:
383 roomId: string, The ID of the room. (required)
384</pre>
385</div>
386
387<div class="method">
388 <code class="details" id="get">get(roomId, language=None)</code>
389 <pre>Get the data for a room.
390
391Args:
392 roomId: string, The ID of the room. (required)
393 language: string, The preferred language to use for strings returned by this method.
394
395Returns:
396 An object of the form:
397
398 { # This is a JSON template for a room resource object.
399 "status": "A String", # The status of the room.
400 # Possible values are:
401 # - "ROOM_INVITING" - One or more players have been invited and not responded.
402 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
403 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
404 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
405 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
406 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
407 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
408 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
409 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
410 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
411 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
412 },
413 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
414 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
415 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
416 "participantId": "A String", # The ID of the participant that modified the room.
417 },
418 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
419 "roomId": "A String", # Globally unique ID for a room.
420 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
421 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
422 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
423 },
424 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
425 { # This is a JSON template for a participant in a room.
426 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
427 "status": "A String", # The status of the participant with respect to the room.
428 # Possible values are:
429 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
430 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
431 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
432 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
433 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
434 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
435 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
436 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
437 "displayName": "A String", # The name to display for the anonymous player.
438 },
439 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
440 # Possible values are:
441 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
442 # - "GAME_LEFT" - The game chose to remove the player from the room.
443 # - "ABANDONED" - The player switched to another application and abandoned the room.
444 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
445 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
446 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
447 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
448 "capabilities": [ # The capabilities which can be used when communicating with this participant.
449 "A String",
450 ],
451 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800452 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400453 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
454 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700455 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
456 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
457 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400458 },
Craig Citro065b5302014-08-14 00:47:23 -0700459 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400460 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
461 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
462 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
463 },
464 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800465 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700466 "title": "A String", # The player's title rewarded for their game activities.
467 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
468 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
469 "currentExperiencePoints": "A String", # The current number of experience points for the player.
470 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
471 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
472 "maxExperiencePoints": "A String", # The maximum experience points for this level.
473 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
474 "minExperiencePoints": "A String", # The minimum experience points for this level.
475 "level": 42, # The level for the user.
476 },
477 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
478 "maxExperiencePoints": "A String", # The maximum experience points for this level.
479 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
480 "minExperiencePoints": "A String", # The minimum experience points for this level.
481 "level": 42, # The level for the user.
482 },
483 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800484 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400485 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
486 },
487 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
488 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
489 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
490 },
491 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
492 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
493 },
494 ],
495 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
496 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
497 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
498 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
499 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
500 "participantId": "A String", # The ID of the participant that modified the room.
501 },
502 "applicationId": "A String", # The ID of the application being played.
503 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
504 }</pre>
505</div>
506
507<div class="method">
508 <code class="details" id="join">join(roomId, body, language=None)</code>
509 <pre>Join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
510
511Args:
512 roomId: string, The ID of the room. (required)
513 body: object, The request body. (required)
514 The object takes the form of:
515
516{ # This is a JSON template for a join room request.
517 "networkDiagnostics": { # This is a JSON template for network diagnostics reported for a client. # Network diagnostics for the client joining the room.
John Asmuth614db982014-04-24 15:46:26 -0400518 "kind": "games#networkDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#networkDiagnostics.
Craig Citro065b5302014-08-14 00:47:23 -0700519 "iosNetworkType": 42, # iOS network type as defined in Reachability.h.
520 "networkOperatorCode": "A String", # The MCC+MNC code for the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperator() On iOS, see: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html
John Asmuth614db982014-04-24 15:46:26 -0400521 "androidNetworkSubtype": 42, # The Android network subtype.
Craig Citro065b5302014-08-14 00:47:23 -0700522 "networkOperatorName": "A String", # The name of the carrier of the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperatorName() On iOS: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html#//apple_ref/occ/instp/CTCarrier/carrierName
523 "registrationLatencyMillis": 42, # The amount of time in milliseconds it took for the client to establish a connection with the XMPP server.
John Asmuth614db982014-04-24 15:46:26 -0400524 "androidNetworkType": 42, # The Android network type.
525 },
526 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the player joining the room.
527 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
528 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
529 },
530 "kind": "games#roomJoinRequest", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomJoinRequest.
531 "capabilities": [ # The capabilities that this client supports for realtime communication.
532 "A String",
533 ],
534 }
535
536 language: string, The preferred language to use for strings returned by this method.
537
538Returns:
539 An object of the form:
540
541 { # This is a JSON template for a room resource object.
542 "status": "A String", # The status of the room.
543 # Possible values are:
544 # - "ROOM_INVITING" - One or more players have been invited and not responded.
545 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
546 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
547 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
548 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
549 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
550 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
551 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
552 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
553 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
554 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
555 },
556 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
557 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
558 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
559 "participantId": "A String", # The ID of the participant that modified the room.
560 },
561 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
562 "roomId": "A String", # Globally unique ID for a room.
563 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
564 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
565 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
566 },
567 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
568 { # This is a JSON template for a participant in a room.
569 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
570 "status": "A String", # The status of the participant with respect to the room.
571 # Possible values are:
572 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
573 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
574 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
575 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
576 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
577 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
578 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
579 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
580 "displayName": "A String", # The name to display for the anonymous player.
581 },
582 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
583 # Possible values are:
584 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
585 # - "GAME_LEFT" - The game chose to remove the player from the room.
586 # - "ABANDONED" - The player switched to another application and abandoned the room.
587 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
588 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
589 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
590 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
591 "capabilities": [ # The capabilities which can be used when communicating with this participant.
592 "A String",
593 ],
594 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800595 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400596 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
597 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700598 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
599 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
600 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400601 },
Craig Citro065b5302014-08-14 00:47:23 -0700602 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400603 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
604 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
605 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
606 },
607 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800608 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700609 "title": "A String", # The player's title rewarded for their game activities.
610 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
611 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
612 "currentExperiencePoints": "A String", # The current number of experience points for the player.
613 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
614 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
615 "maxExperiencePoints": "A String", # The maximum experience points for this level.
616 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
617 "minExperiencePoints": "A String", # The minimum experience points for this level.
618 "level": 42, # The level for the user.
619 },
620 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
621 "maxExperiencePoints": "A String", # The maximum experience points for this level.
622 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
623 "minExperiencePoints": "A String", # The minimum experience points for this level.
624 "level": 42, # The level for the user.
625 },
626 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800627 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400628 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
629 },
630 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
631 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
632 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
633 },
634 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
635 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
636 },
637 ],
638 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
639 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
640 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
641 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
642 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
643 "participantId": "A String", # The ID of the participant that modified the room.
644 },
645 "applicationId": "A String", # The ID of the application being played.
646 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
647 }</pre>
648</div>
649
650<div class="method">
651 <code class="details" id="leave">leave(roomId, body, language=None)</code>
652 <pre>Leave a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
653
654Args:
655 roomId: string, The ID of the room. (required)
656 body: object, The request body. (required)
657 The object takes the form of:
658
659{ # This is a JSON template for a leave room request.
660 "kind": "games#roomLeaveRequest", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomLeaveRequest.
661 "reason": "A String", # Reason for leaving the match.
662 # Possible values are:
663 # - "PLAYER_LEFT" - The player chose to leave the room..
664 # - "GAME_LEFT" - The game chose to remove the player from the room.
665 # - "REALTIME_ABANDONED" - The player switched to another application and abandoned the room.
666 # - "REALTIME_PEER_CONNECTION_FAILURE" - The client was unable to establish a connection to other peer(s).
667 # - "REALTIME_SERVER_CONNECTION_FAILURE" - The client was unable to communicate with the server.
668 # - "REALTIME_SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
669 # - "REALTIME_TIMEOUT" - The client timed out while waiting for a room.
Craig Citro065b5302014-08-14 00:47:23 -0700670 # - "REALTIME_CLIENT_DISCONNECTING" - The client disconnects without first calling Leave.
671 # - "REALTIME_SIGN_OUT" - The user signed out of G+ while in the room.
672 # - "REALTIME_GAME_CRASHED" - The game crashed.
673 # - "REALTIME_ROOM_SERVICE_CRASHED" - RoomAndroidService crashed.
674 # - "REALTIME_DIFFERENT_CLIENT_ROOM_OPERATION" - Another client is trying to enter a room.
675 # - "REALTIME_SAME_CLIENT_ROOM_OPERATION" - The same client is trying to enter a new room.
John Asmuth614db982014-04-24 15:46:26 -0400676 "leaveDiagnostics": { # This is a JSON template for room leave diagnostics. # Diagnostics for a player leaving the room.
677 "kind": "games#roomLeaveDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomLeaveDiagnostics.
678 "socketsUsed": True or False, # Whether or not sockets were used.
679 "iosNetworkType": 42, # iOS network type as defined in Reachability.h.
Craig Citro065b5302014-08-14 00:47:23 -0700680 "networkOperatorCode": "A String", # The MCC+MNC code for the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperator() On iOS, see: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html
John Asmuth614db982014-04-24 15:46:26 -0400681 "peerSession": [ # Diagnostics about all peer sessions.
682 { # This is a JSON template for peer session diagnostics.
683 "unreliableChannel": { # This is a JSON template for peer channel diagnostics. # Unreliable channel diagnostics.
684 "bytesReceived": { # This is a JSON template for aggregate stats. # Number of bytes received.
685 "count": "A String", # The number of messages sent between a pair of peers.
686 "max": "A String", # The maximum amount.
687 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
688 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
689 "min": "A String", # The minimum amount.
690 },
691 "kind": "games#peerChannelDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#peerChannelDiagnostics.
692 "bytesSent": { # This is a JSON template for aggregate stats. # Number of bytes sent.
693 "count": "A String", # The number of messages sent between a pair of peers.
694 "max": "A String", # The maximum amount.
695 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
696 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
697 "min": "A String", # The minimum amount.
698 },
699 "numSendFailures": 42, # Number of send failures.
700 "numMessagesLost": 42, # Number of messages lost.
701 "numMessagesReceived": 42, # Number of messages received.
702 "numMessagesSent": 42, # Number of messages sent.
703 "roundtripLatencyMillis": { # This is a JSON template for aggregate stats. # Roundtrip latency stats in milliseconds.
704 "count": "A String", # The number of messages sent between a pair of peers.
705 "max": "A String", # The maximum amount.
706 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
707 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
708 "min": "A String", # The minimum amount.
709 },
710 },
711 "kind": "games#peerSessionDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#peerSessionDiagnostics.
712 "reliableChannel": { # This is a JSON template for peer channel diagnostics. # Reliable channel diagnostics.
713 "bytesReceived": { # This is a JSON template for aggregate stats. # Number of bytes received.
714 "count": "A String", # The number of messages sent between a pair of peers.
715 "max": "A String", # The maximum amount.
716 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
717 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
718 "min": "A String", # The minimum amount.
719 },
720 "kind": "games#peerChannelDiagnostics", # Uniquely identifies the type of this resource. Value is always the fixed string games#peerChannelDiagnostics.
721 "bytesSent": { # This is a JSON template for aggregate stats. # Number of bytes sent.
722 "count": "A String", # The number of messages sent between a pair of peers.
723 "max": "A String", # The maximum amount.
724 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
725 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
726 "min": "A String", # The minimum amount.
727 },
728 "numSendFailures": 42, # Number of send failures.
729 "numMessagesLost": 42, # Number of messages lost.
730 "numMessagesReceived": 42, # Number of messages received.
731 "numMessagesSent": 42, # Number of messages sent.
732 "roundtripLatencyMillis": { # This is a JSON template for aggregate stats. # Roundtrip latency stats in milliseconds.
733 "count": "A String", # The number of messages sent between a pair of peers.
734 "max": "A String", # The maximum amount.
735 "kind": "games#aggregateStats", # Uniquely identifies the type of this resource. Value is always the fixed string games#aggregateStats.
736 "sum": "A String", # The total number of bytes sent for messages between a pair of peers.
737 "min": "A String", # The minimum amount.
738 },
739 },
740 "connectedTimestampMillis": "A String", # Connected time in milliseconds.
741 "participantId": "A String", # The participant ID of the peer.
742 },
743 ],
744 "androidNetworkSubtype": 42, # Android network subtype. http://developer.android.com/reference/android/net/NetworkInfo.html#getSubtype()
Craig Citro065b5302014-08-14 00:47:23 -0700745 "networkOperatorName": "A String", # The name of the carrier of the client's network connection. On Android: http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperatorName() On iOS: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/Reference.html#//apple_ref/occ/instp/CTCarrier/carrierName
John Asmuth614db982014-04-24 15:46:26 -0400746 "androidNetworkType": 42, # Android network type. http://developer.android.com/reference/android/net/NetworkInfo.html#getType()
747 },
748 }
749
750 language: string, The preferred language to use for strings returned by this method.
751
752Returns:
753 An object of the form:
754
755 { # This is a JSON template for a room resource object.
756 "status": "A String", # The status of the room.
757 # Possible values are:
758 # - "ROOM_INVITING" - One or more players have been invited and not responded.
759 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
760 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
761 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
762 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
763 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
764 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
765 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
766 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
767 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
768 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
769 },
770 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
771 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
772 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
773 "participantId": "A String", # The ID of the participant that modified the room.
774 },
775 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
776 "roomId": "A String", # Globally unique ID for a room.
777 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
778 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
779 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
780 },
781 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
782 { # This is a JSON template for a participant in a room.
783 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
784 "status": "A String", # The status of the participant with respect to the room.
785 # Possible values are:
786 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
787 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
788 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
789 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
790 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
791 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
792 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
793 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
794 "displayName": "A String", # The name to display for the anonymous player.
795 },
796 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
797 # Possible values are:
798 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
799 # - "GAME_LEFT" - The game chose to remove the player from the room.
800 # - "ABANDONED" - The player switched to another application and abandoned the room.
801 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
802 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
803 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
804 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
805 "capabilities": [ # The capabilities which can be used when communicating with this participant.
806 "A String",
807 ],
808 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800809 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400810 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
811 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700812 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
813 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
814 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400815 },
Craig Citro065b5302014-08-14 00:47:23 -0700816 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400817 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
818 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
819 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
820 },
821 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800822 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700823 "title": "A String", # The player's title rewarded for their game activities.
824 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
825 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
826 "currentExperiencePoints": "A String", # The current number of experience points for the player.
827 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
828 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
829 "maxExperiencePoints": "A String", # The maximum experience points for this level.
830 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
831 "minExperiencePoints": "A String", # The minimum experience points for this level.
832 "level": 42, # The level for the user.
833 },
834 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
835 "maxExperiencePoints": "A String", # The maximum experience points for this level.
836 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
837 "minExperiencePoints": "A String", # The minimum experience points for this level.
838 "level": 42, # The level for the user.
839 },
840 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800841 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400842 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
843 },
844 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
845 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
846 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
847 },
848 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
849 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
850 },
851 ],
852 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
853 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
854 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
855 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
856 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
857 "participantId": "A String", # The ID of the participant that modified the room.
858 },
859 "applicationId": "A String", # The ID of the application being played.
860 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
861 }</pre>
862</div>
863
864<div class="method">
865 <code class="details" id="list">list(pageToken=None, language=None, maxResults=None)</code>
866 <pre>Returns invitations to join rooms.
867
868Args:
869 pageToken: string, The token returned by the previous request.
870 language: string, The preferred language to use for strings returned by this method.
871 maxResults: integer, The maximum number of rooms to return in the response, used for paging. For any response, the actual number of rooms to return may be less than the specified maxResults.
872
873Returns:
874 An object of the form:
875
876 { # This is a JSON template for a list of rooms.
877 "nextPageToken": "A String", # The pagination token for the next page of results.
878 "items": [ # The rooms.
879 { # This is a JSON template for a room resource object.
880 "status": "A String", # The status of the room.
881 # Possible values are:
882 # - "ROOM_INVITING" - One or more players have been invited and not responded.
883 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
884 # - "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-matching).
885 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
886 # - "ROOM_DELETED" - The room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a tombstone), or for rooms where all joined participants have left.
887 "kind": "games#room", # Uniquely identifies the type of this resource. Value is always the fixed string games#room.
888 "autoMatchingCriteria": { # This is a JSON template for a room auto-match criteria object. # Criteria for auto-matching players into this room.
889 "kind": "games#roomAutoMatchingCriteria", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria.
890 "minAutoMatchingPlayers": 42, # The minimum number of players that should be added to the room by auto-matching.
891 "exclusiveBitmask": "A String", # A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game.
892 "maxAutoMatchingPlayers": 42, # The maximum number of players that should be added to the room by auto-matching.
893 },
894 "creationDetails": { # This is a JSON template for room modification metadata. # Details about the room creation.
895 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
896 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
897 "participantId": "A String", # The ID of the participant that modified the room.
898 },
899 "description": "A String", # This short description is generated by our servers and worded relative to the player requesting the room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a room.)
900 "roomId": "A String", # Globally unique ID for a room.
901 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the auto-matching queue.
902 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
903 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
904 },
905 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
906 { # This is a JSON template for a participant in a room.
907 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
908 "status": "A String", # The status of the participant with respect to the room.
909 # Possible values are:
910 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
911 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
912 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
913 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
914 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
915 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
916 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
917 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
918 "displayName": "A String", # The name to display for the anonymous player.
919 },
920 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
921 # Possible values are:
922 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
923 # - "GAME_LEFT" - The game chose to remove the player from the room.
924 # - "ABANDONED" - The player switched to another application and abandoned the room.
925 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
926 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
927 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
928 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
929 "capabilities": [ # The capabilities which can be used when communicating with this participant.
930 "A String",
931 ],
932 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800933 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -0400934 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
935 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -0700936 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
937 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
938 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -0400939 },
Craig Citro065b5302014-08-14 00:47:23 -0700940 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -0400941 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
942 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
943 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
944 },
945 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800946 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -0700947 "title": "A String", # The player's title rewarded for their game activities.
948 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
949 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
950 "currentExperiencePoints": "A String", # The current number of experience points for the player.
951 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
952 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
953 "maxExperiencePoints": "A String", # The maximum experience points for this level.
954 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
955 "minExperiencePoints": "A String", # The minimum experience points for this level.
956 "level": 42, # The level for the user.
957 },
958 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
959 "maxExperiencePoints": "A String", # The maximum experience points for this level.
960 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
961 "minExperiencePoints": "A String", # The minimum experience points for this level.
962 "level": 42, # The level for the user.
963 },
964 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800965 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -0400966 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
967 },
968 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
969 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
970 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
971 },
972 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
973 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
974 },
975 ],
976 "roomStatusVersion": 42, # The version of the room status: an increasing counter, used by the client to ignore out-of-order updates to room status.
977 "variant": 42, # The variant / mode of the application being played; can be any integer value, or left blank.
978 "lastUpdateDetails": { # This is a JSON template for room modification metadata. # Details about the last update to the room.
979 "kind": "games#roomModification", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomModification.
980 "modifiedTimestampMillis": "A String", # The timestamp at which they modified the room, in milliseconds since the epoch in UTC.
981 "participantId": "A String", # The ID of the participant that modified the room.
982 },
983 "applicationId": "A String", # The ID of the application being played.
984 "inviterId": "A String", # The ID of the participant that invited the user to the room. Not set if the user was not invited to the room.
985 },
986 ],
987 "kind": "games#roomList", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomList.
988 }</pre>
989</div>
990
991<div class="method">
992 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
993 <pre>Retrieves the next page of results.
994
995Args:
996 previous_request: The request for the previous page. (required)
997 previous_response: The response from the request for the previous page. (required)
998
999Returns:
1000 A request object that you can call 'execute()' on to request the next
1001 page. Returns None if there are no more items in the collection.
1002 </pre>
1003</div>
1004
1005<div class="method">
1006 <code class="details" id="reportStatus">reportStatus(roomId, body, language=None)</code>
1007 <pre>Updates sent by a client reporting the status of peers in a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
1008
1009Args:
1010 roomId: string, The ID of the room. (required)
1011 body: object, The request body. (required)
1012 The object takes the form of:
1013
1014{ # This is a JSON template for an update on the status of peers in a room.
1015 "kind": "games#roomP2PStatuses", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomP2PStatuses.
1016 "updates": [ # The updates for the peers.
1017 { # This is a JSON template for an update on the status of a peer in a room.
1018 "status": "A String", # The status of the peer in the room.
1019 # Possible values are:
1020 # - "CONNECTION_ESTABLISHED" - The client established a P2P connection with the peer.
1021 # - "CONNECTION_FAILED" - The client failed to establish directed presence with the peer.
1022 "kind": "games#roomP2PStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomP2PStatus.
1023 "participantId": "A String", # The ID of the participant.
1024 "unreliableRoundtripLatencyMillis": 42, # The amount of time in milliseconds it took to send packets back and forth on the unreliable channel with this peer.
1025 "connectionSetupLatencyMillis": 42, # The amount of time in milliseconds it took to establish connections with this peer.
1026 "error": "A String", # The error code in event of a failure.
1027 # Possible values are:
1028 # - "P2P_FAILED" - The client failed to establish a P2P connection with the peer.
1029 # - "PRESENCE_FAILED" - The client failed to register to receive P2P connections.
1030 # - "RELAY_SERVER_FAILED" - The client received an error when trying to use the relay server to establish a P2P connection with the peer.
1031 "error_reason": "A String", # More detailed diagnostic message returned in event of a failure.
1032 },
1033 ],
1034 }
1035
1036 language: string, The preferred language to use for strings returned by this method.
1037
1038Returns:
1039 An object of the form:
1040
1041 { # This is a JSON template for the status of a room that the player has joined.
1042 "status": "A String", # The status of the room.
1043 # Possible values are:
1044 # - "ROOM_INVITING" - One or more players have been invited and not responded.
1045 # - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching.
1046 # - "ROOM_CONNECTING" - Players have joined are connecting to each other (either before or after auto-matching).
1047 # - "ROOM_ACTIVE" - All players have joined and connected to each other.
1048 # - "ROOM_DELETED" - All joined players have left.
1049 "kind": "games#roomStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomStatus.
1050 "autoMatchingStatus": { # This is a JSON template for status of room automatching that is in progress. # Auto-matching status for this room. Not set if the room is not currently in the automatching queue.
1051 "kind": "games#roomAutoMatchStatus", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchStatus.
1052 "waitEstimateSeconds": 42, # An estimate for the amount of time (in seconds) that auto-matching is expected to take to complete.
1053 },
1054 "participants": [ # The participants involved in the room, along with their statuses. Includes participants who have left or declined invitations.
1055 { # This is a JSON template for a participant in a room.
1056 "autoMatched": True or False, # True if this participant was auto-matched with the requesting player.
1057 "status": "A String", # The status of the participant with respect to the room.
1058 # Possible values are:
1059 # - "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded.
1060 # - "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an invitation.)
1061 # - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room.
1062 # - "PARTICIPANT_LEFT" - The participant joined the room and then left it.
1063 "kind": "games#roomParticipant", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomParticipant.
1064 "autoMatchedPlayer": { # This is a JSON template for an anonymous player # Information about a player that has been anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
1065 "kind": "games#anonymousPlayer", # Uniquely identifies the type of this resource. Value is always the fixed string games#anonymousPlayer.
1066 "avatarImageUrl": "A String", # The base URL for the image to display for the anonymous player.
1067 "displayName": "A String", # The name to display for the anonymous player.
1068 },
1069 "leaveReason": "A String", # The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
1070 # Possible values are:
1071 # - "PLAYER_LEFT" - The player explicitly chose to leave the room.
1072 # - "GAME_LEFT" - The game chose to remove the player from the room.
1073 # - "ABANDONED" - The player switched to another application and abandoned the room.
1074 # - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a connection to other peer(s) in the room.
1075 # - "SERVER_ERROR" - The client received an error response when it tried to communicate with the server.
1076 # - "TIMEOUT" - The client timed out while waiting for players to join and connect.
1077 # - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.
1078 "capabilities": [ # The capabilities which can be used when communicating with this participant.
1079 "A String",
1080 ],
1081 "player": { # This is a JSON template for a Player resource. # Information about the player. Not populated if this player was anonymously auto-matched against the requesting player. (Either player or autoMatchedPlayer will be set.)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001082 "originalPlayerId": "A String", # The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs.
John Asmuth614db982014-04-24 15:46:26 -04001083 "kind": "games#player", # Uniquely identifies the type of this resource. Value is always the fixed string games#player.
1084 "displayName": "A String", # The name to display for the player.
Craig Citro065b5302014-08-14 00:47:23 -07001085 "name": { # An object representation of the individual components of the player's name. For some players, these fields may not be present.
1086 "givenName": "A String", # The given name of this player. In some places, this is known as the first name.
1087 "familyName": "A String", # The family name of this player. In some places, this is known as the last name.
John Asmuth614db982014-04-24 15:46:26 -04001088 },
Craig Citro065b5302014-08-14 00:47:23 -07001089 "lastPlayedWith": { # This is a JSON template for metadata about a player playing a game with the currently authenticated user. # Details about the last time this player played a multiplayer game with the currently authenticated player. Populated for PLAYED_WITH player collection members.
John Asmuth614db982014-04-24 15:46:26 -04001090 "autoMatched": True or False, # True if the player was auto-matched with the currently authenticated user.
1091 "kind": "games#played", # Uniquely identifies the type of this resource. Value is always the fixed string games#played.
1092 "timeMillis": "A String", # The last time the player played the game in milliseconds since the epoch in UTC.
1093 },
1094 "playerId": "A String", # The ID of the player.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001095 "bannerUrlPortrait": "A String", # The url to the portrait mode player banner image.
Craig Citro065b5302014-08-14 00:47:23 -07001096 "title": "A String", # The player's title rewarded for their game activities.
1097 "experienceInfo": { # This is a JSON template for 1P/3P metadata about the player's experience. # An object to represent Play Game experience information for the player.
1098 "lastLevelUpTimestampMillis": "A String", # The timestamp when the player was leveled up, in millis since Unix epoch UTC.
1099 "currentExperiencePoints": "A String", # The current number of experience points for the player.
1100 "kind": "games#playerExperienceInfo", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerExperienceInfo.
1101 "currentLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The current level of the player.
1102 "maxExperiencePoints": "A String", # The maximum experience points for this level.
1103 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
1104 "minExperiencePoints": "A String", # The minimum experience points for this level.
1105 "level": 42, # The level for the user.
1106 },
1107 "nextLevel": { # This is a JSON template for 1P/3P metadata about a user's level. # The next level of the player. If the current level is the maximum level, this should be same as the current level.
1108 "maxExperiencePoints": "A String", # The maximum experience points for this level.
1109 "kind": "games#playerLevel", # Uniquely identifies the type of this resource. Value is always the fixed string games#playerLevel.
1110 "minExperiencePoints": "A String", # The minimum experience points for this level.
1111 "level": 42, # The level for the user.
1112 },
1113 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001114 "bannerUrlLandscape": "A String", # The url to the landscape mode player banner image.
John Asmuth614db982014-04-24 15:46:26 -04001115 "avatarImageUrl": "A String", # The base URL for the image that represents the player.
1116 },
1117 "clientAddress": { # This is a JSON template for the client address when setting up a room. # Client address for the participant.
1118 "kind": "games#roomClientAddress", # Uniquely identifies the type of this resource. Value is always the fixed string games#roomClientAddress.
1119 "xmppAddress": "A String", # The XMPP address of the client on the Google Games XMPP network.
1120 },
1121 "connected": True or False, # True if this participant is in the fully connected set of peers in the room.
1122 "id": "A String", # An identifier for the participant in the scope of the room. Cannot be used to identify a player across rooms or in other contexts.
1123 },
1124 ],
1125 "statusVersion": 42, # The version of the status for the room: an increasing counter, used by the client to ignore out-of-order updates to room status.
1126 "roomId": "A String", # Globally unique ID for a room.
1127 }</pre>
1128</div>
1129
1130</body></html>