Documentation ¶
Overview ¶
Package games provides access to the Google Play Game Services API.
See https://developers.google.com/games/services/
Usage example:
import "code.google.com/p/google-api-go-client/games/v1" ... gamesService, err := games.New(oauthHttpClient)
Index ¶
- Constants
- type AchievementDefinition
- type AchievementDefinitionsListCall
- func (c *AchievementDefinitionsListCall) Do() (*AchievementDefinitionsListResponse, error)
- func (c *AchievementDefinitionsListCall) Language(language string) *AchievementDefinitionsListCall
- func (c *AchievementDefinitionsListCall) MaxResults(maxResults int64) *AchievementDefinitionsListCall
- func (c *AchievementDefinitionsListCall) PageToken(pageToken string) *AchievementDefinitionsListCall
- type AchievementDefinitionsListResponse
- type AchievementDefinitionsService
- type AchievementIncrementResponse
- type AchievementRevealResponse
- type AchievementSetStepsAtLeastResponse
- type AchievementUnlockResponse
- type AchievementUpdateMultipleRequest
- type AchievementUpdateMultipleResponse
- type AchievementUpdateRequest
- type AchievementUpdateResponse
- type AchievementsIncrementCall
- type AchievementsListCall
- func (c *AchievementsListCall) Do() (*PlayerAchievementListResponse, error)
- func (c *AchievementsListCall) Language(language string) *AchievementsListCall
- func (c *AchievementsListCall) MaxResults(maxResults int64) *AchievementsListCall
- func (c *AchievementsListCall) PageToken(pageToken string) *AchievementsListCall
- func (c *AchievementsListCall) State(state string) *AchievementsListCall
- type AchievementsRevealCall
- type AchievementsService
- func (r *AchievementsService) Increment(achievementId string, stepsToIncrement int64) *AchievementsIncrementCall
- func (r *AchievementsService) List(playerId string) *AchievementsListCall
- func (r *AchievementsService) Reveal(achievementId string) *AchievementsRevealCall
- func (r *AchievementsService) SetStepsAtLeast(achievementId string, steps int64) *AchievementsSetStepsAtLeastCall
- func (r *AchievementsService) Unlock(achievementId string) *AchievementsUnlockCall
- func (r *AchievementsService) UpdateMultiple(achievementupdatemultiplerequest *AchievementUpdateMultipleRequest) *AchievementsUpdateMultipleCall
- type AchievementsSetStepsAtLeastCall
- type AchievementsUnlockCall
- type AchievementsUpdateMultipleCall
- type AggregateStats
- type AnonymousPlayer
- type Application
- type ApplicationCategory
- type ApplicationsGetCall
- type ApplicationsPlayedCall
- type ApplicationsService
- type GamesAchievementIncrement
- type GamesAchievementSetStepsAtLeast
- type ImageAsset
- type Instance
- type InstanceAndroidDetails
- type InstanceIosDetails
- type InstanceWebDetails
- type Leaderboard
- type LeaderboardEntry
- type LeaderboardListResponse
- type LeaderboardScoreRank
- type LeaderboardScores
- type LeaderboardsGetCall
- type LeaderboardsListCall
- func (c *LeaderboardsListCall) Do() (*LeaderboardListResponse, error)
- func (c *LeaderboardsListCall) Language(language string) *LeaderboardsListCall
- func (c *LeaderboardsListCall) MaxResults(maxResults int64) *LeaderboardsListCall
- func (c *LeaderboardsListCall) PageToken(pageToken string) *LeaderboardsListCall
- type LeaderboardsService
- type NetworkDiagnostics
- type ParticipantResult
- type PeerChannelDiagnostics
- type PeerSessionDiagnostics
- type Played
- type Player
- type PlayerAchievement
- type PlayerAchievementListResponse
- type PlayerLeaderboardScore
- type PlayerLeaderboardScoreListResponse
- type PlayerListResponse
- type PlayerName
- type PlayerScore
- type PlayerScoreListResponse
- type PlayerScoreResponse
- type PlayerScoreSubmissionList
- type PlayersGetCall
- type PlayersListCall
- type PlayersService
- type PushToken
- type PushTokenId
- type PushTokenIdIos
- type PushtokensRemoveCall
- type PushtokensService
- type PushtokensUpdateCall
- type RevisionCheckResponse
- type RevisionsCheckCall
- type RevisionsService
- type Room
- type RoomAutoMatchStatus
- type RoomAutoMatchingCriteria
- type RoomClientAddress
- type RoomCreateRequest
- type RoomJoinRequest
- type RoomLeaveDiagnostics
- type RoomLeaveRequest
- type RoomList
- type RoomModification
- type RoomP2PStatus
- type RoomP2PStatuses
- type RoomParticipant
- type RoomStatus
- type RoomsCreateCall
- type RoomsDeclineCall
- type RoomsDismissCall
- type RoomsGetCall
- type RoomsJoinCall
- type RoomsLeaveCall
- type RoomsListCall
- type RoomsReportStatusCall
- type RoomsService
- func (r *RoomsService) Create(roomcreaterequest *RoomCreateRequest) *RoomsCreateCall
- func (r *RoomsService) Decline(roomId string) *RoomsDeclineCall
- func (r *RoomsService) Dismiss(roomId string) *RoomsDismissCall
- func (r *RoomsService) Get(roomId string) *RoomsGetCall
- func (r *RoomsService) Join(roomId string, roomjoinrequest *RoomJoinRequest) *RoomsJoinCall
- func (r *RoomsService) Leave(roomId string, roomleaverequest *RoomLeaveRequest) *RoomsLeaveCall
- func (r *RoomsService) List() *RoomsListCall
- func (r *RoomsService) ReportStatus(roomId string, roomp2pstatuses *RoomP2PStatuses) *RoomsReportStatusCall
- type ScoreSubmission
- type ScoresGetCall
- func (c *ScoresGetCall) Do() (*PlayerLeaderboardScoreListResponse, error)
- func (c *ScoresGetCall) IncludeRankType(includeRankType string) *ScoresGetCall
- func (c *ScoresGetCall) Language(language string) *ScoresGetCall
- func (c *ScoresGetCall) MaxResults(maxResults int64) *ScoresGetCall
- func (c *ScoresGetCall) PageToken(pageToken string) *ScoresGetCall
- type ScoresListCall
- type ScoresListWindowCall
- func (c *ScoresListWindowCall) Do() (*LeaderboardScores, error)
- func (c *ScoresListWindowCall) Language(language string) *ScoresListWindowCall
- func (c *ScoresListWindowCall) MaxResults(maxResults int64) *ScoresListWindowCall
- func (c *ScoresListWindowCall) PageToken(pageToken string) *ScoresListWindowCall
- func (c *ScoresListWindowCall) ResultsAbove(resultsAbove int64) *ScoresListWindowCall
- func (c *ScoresListWindowCall) ReturnTopIfAbsent(returnTopIfAbsent bool) *ScoresListWindowCall
- type ScoresService
- func (r *ScoresService) Get(playerId string, leaderboardId string, timeSpan string) *ScoresGetCall
- func (r *ScoresService) List(leaderboardId string, collection string, timeSpan string) *ScoresListCall
- func (r *ScoresService) ListWindow(leaderboardId string, collection string, timeSpan string) *ScoresListWindowCall
- func (r *ScoresService) Submit(leaderboardId string, score int64) *ScoresSubmitCall
- func (r *ScoresService) SubmitMultiple(playerscoresubmissionlist *PlayerScoreSubmissionList) *ScoresSubmitMultipleCall
- type ScoresSubmitCall
- type ScoresSubmitMultipleCall
- type Service
- type TurnBasedAutoMatchingCriteria
- type TurnBasedMatch
- type TurnBasedMatchCreateRequest
- type TurnBasedMatchData
- type TurnBasedMatchDataRequest
- type TurnBasedMatchList
- type TurnBasedMatchModification
- type TurnBasedMatchParticipant
- type TurnBasedMatchRematch
- type TurnBasedMatchResults
- type TurnBasedMatchSync
- type TurnBasedMatchTurn
- type TurnBasedMatchesCancelCall
- type TurnBasedMatchesCreateCall
- type TurnBasedMatchesDeclineCall
- type TurnBasedMatchesDismissCall
- type TurnBasedMatchesFinishCall
- type TurnBasedMatchesGetCall
- type TurnBasedMatchesJoinCall
- type TurnBasedMatchesLeaveCall
- type TurnBasedMatchesLeaveTurnCall
- type TurnBasedMatchesListCall
- func (c *TurnBasedMatchesListCall) Do() (*TurnBasedMatchList, error)
- func (c *TurnBasedMatchesListCall) IncludeMatchData(includeMatchData bool) *TurnBasedMatchesListCall
- func (c *TurnBasedMatchesListCall) Language(language string) *TurnBasedMatchesListCall
- func (c *TurnBasedMatchesListCall) MaxCompletedMatches(maxCompletedMatches int64) *TurnBasedMatchesListCall
- func (c *TurnBasedMatchesListCall) MaxResults(maxResults int64) *TurnBasedMatchesListCall
- func (c *TurnBasedMatchesListCall) PageToken(pageToken string) *TurnBasedMatchesListCall
- type TurnBasedMatchesRematchCall
- type TurnBasedMatchesService
- func (r *TurnBasedMatchesService) Cancel(matchId string) *TurnBasedMatchesCancelCall
- func (r *TurnBasedMatchesService) Create(turnbasedmatchcreaterequest *TurnBasedMatchCreateRequest) *TurnBasedMatchesCreateCall
- func (r *TurnBasedMatchesService) Decline(matchId string) *TurnBasedMatchesDeclineCall
- func (r *TurnBasedMatchesService) Dismiss(matchId string) *TurnBasedMatchesDismissCall
- func (r *TurnBasedMatchesService) Finish(matchId string, turnbasedmatchresults *TurnBasedMatchResults) *TurnBasedMatchesFinishCall
- func (r *TurnBasedMatchesService) Get(matchId string) *TurnBasedMatchesGetCall
- func (r *TurnBasedMatchesService) Join(matchId string) *TurnBasedMatchesJoinCall
- func (r *TurnBasedMatchesService) Leave(matchId string) *TurnBasedMatchesLeaveCall
- func (r *TurnBasedMatchesService) LeaveTurn(matchId string, matchVersion int64) *TurnBasedMatchesLeaveTurnCall
- func (r *TurnBasedMatchesService) List() *TurnBasedMatchesListCall
- func (r *TurnBasedMatchesService) Rematch(matchId string) *TurnBasedMatchesRematchCall
- func (r *TurnBasedMatchesService) Sync() *TurnBasedMatchesSyncCall
- func (r *TurnBasedMatchesService) TakeTurn(matchId string, turnbasedmatchturn *TurnBasedMatchTurn) *TurnBasedMatchesTakeTurnCall
- type TurnBasedMatchesSyncCall
- func (c *TurnBasedMatchesSyncCall) Do() (*TurnBasedMatchSync, error)
- func (c *TurnBasedMatchesSyncCall) IncludeMatchData(includeMatchData bool) *TurnBasedMatchesSyncCall
- func (c *TurnBasedMatchesSyncCall) Language(language string) *TurnBasedMatchesSyncCall
- func (c *TurnBasedMatchesSyncCall) MaxCompletedMatches(maxCompletedMatches int64) *TurnBasedMatchesSyncCall
- func (c *TurnBasedMatchesSyncCall) MaxResults(maxResults int64) *TurnBasedMatchesSyncCall
- func (c *TurnBasedMatchesSyncCall) PageToken(pageToken string) *TurnBasedMatchesSyncCall
- type TurnBasedMatchesTakeTurnCall
Constants ¶
const ( // Share your Google+ profile information and view and manage your game // activity GamesScope = "https://www.googleapis.com/auth/games" // Know your basic profile info and list of people in your circles. PlusLoginScope = "https://www.googleapis.com/auth/plus.login" )
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AchievementDefinition ¶
type AchievementDefinition struct { // AchievementType: The type of the achievement. // Possible values are: // // - "STANDARD" - Achievement is either locked or unlocked. // - // "INCREMENTAL" - Achievement is incremental. AchievementType string `json:"achievementType,omitempty"` // Description: The description of the achievement. Description string `json:"description,omitempty"` // FormattedTotalSteps: The total steps for an incremental achievement // as a string. FormattedTotalSteps string `json:"formattedTotalSteps,omitempty"` // Id: The ID of the achievement. Id string `json:"id,omitempty"` // InitialState: The initial state of the achievement. // Possible values // are: // - "HIDDEN" - Achievement is hidden. // - "REVEALED" - // Achievement is revealed. // - "UNLOCKED" - Achievement is unlocked. InitialState string `json:"initialState,omitempty"` // IsRevealedIconUrlDefault: Indicates whether the revealed icon image // being returned is a default image, or is provided by the game. IsRevealedIconUrlDefault bool `json:"isRevealedIconUrlDefault,omitempty"` // IsUnlockedIconUrlDefault: Indicates whether the unlocked icon image // being returned is a default image, or is game-provided. IsUnlockedIconUrlDefault bool `json:"isUnlockedIconUrlDefault,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementDefinition. Kind string `json:"kind,omitempty"` // Name: The name of the achievement. Name string `json:"name,omitempty"` // RevealedIconUrl: The image URL for the revealed achievement icon. RevealedIconUrl string `json:"revealedIconUrl,omitempty"` // TotalSteps: The total steps for an incremental achievement. TotalSteps int64 `json:"totalSteps,omitempty"` // UnlockedIconUrl: The image URL for the unlocked achievement icon. UnlockedIconUrl string `json:"unlockedIconUrl,omitempty"` }
type AchievementDefinitionsListCall ¶
type AchievementDefinitionsListCall struct {
// contains filtered or unexported fields
}
func (*AchievementDefinitionsListCall) Do ¶
func (c *AchievementDefinitionsListCall) Do() (*AchievementDefinitionsListResponse, error)
func (*AchievementDefinitionsListCall) Language ¶
func (c *AchievementDefinitionsListCall) Language(language string) *AchievementDefinitionsListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*AchievementDefinitionsListCall) MaxResults ¶
func (c *AchievementDefinitionsListCall) MaxResults(maxResults int64) *AchievementDefinitionsListCall
MaxResults sets the optional parameter "maxResults": The maximum number of achievement resources to return in the response, used for paging. For any response, the actual number of achievement resources returned may be less than the specified maxResults.
func (*AchievementDefinitionsListCall) PageToken ¶
func (c *AchievementDefinitionsListCall) PageToken(pageToken string) *AchievementDefinitionsListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type AchievementDefinitionsListResponse ¶
type AchievementDefinitionsListResponse struct { // Items: The achievement definitions. Items []*AchievementDefinition `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementDefinitionsListResponse. Kind string `json:"kind,omitempty"` // NextPageToken: Token corresponding to the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type AchievementDefinitionsService ¶
type AchievementDefinitionsService struct {
// contains filtered or unexported fields
}
func NewAchievementDefinitionsService ¶
func NewAchievementDefinitionsService(s *Service) *AchievementDefinitionsService
func (*AchievementDefinitionsService) List ¶
func (r *AchievementDefinitionsService) List() *AchievementDefinitionsListCall
List: Lists all the achievement definitions for your application.
type AchievementIncrementResponse ¶
type AchievementIncrementResponse struct { // CurrentSteps: The current steps recorded for this incremental // achievement. CurrentSteps int64 `json:"currentSteps,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementIncrementResponse. Kind string `json:"kind,omitempty"` // NewlyUnlocked: Whether the the current steps for the achievement has // reached the number of steps required to unlock. NewlyUnlocked bool `json:"newlyUnlocked,omitempty"` }
type AchievementRevealResponse ¶
type AchievementRevealResponse struct { // CurrentState: The current state of the achievement for which a reveal // was attempted. This might be UNLOCKED if the achievement was already // unlocked. // Possible values are: // - "REVEALED" - Achievement is // revealed. // - "UNLOCKED" - Achievement is unlocked. CurrentState string `json:"currentState,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementRevealResponse. Kind string `json:"kind,omitempty"` }
type AchievementSetStepsAtLeastResponse ¶
type AchievementSetStepsAtLeastResponse struct { // CurrentSteps: The current steps recorded for this incremental // achievement. CurrentSteps int64 `json:"currentSteps,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementSetStepsAtLeastResponse. Kind string `json:"kind,omitempty"` // NewlyUnlocked: Whether the the current steps for the achievement has // reached the number of steps required to unlock. NewlyUnlocked bool `json:"newlyUnlocked,omitempty"` }
type AchievementUnlockResponse ¶
type AchievementUnlockResponse struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementUnlockResponse. Kind string `json:"kind,omitempty"` // NewlyUnlocked: Whether this achievement was newly unlocked (that is, // whether the unlock request for the achievement was the first for the // player). NewlyUnlocked bool `json:"newlyUnlocked,omitempty"` }
type AchievementUpdateMultipleRequest ¶
type AchievementUpdateMultipleRequest struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementUpdateMultipleRequest. Kind string `json:"kind,omitempty"` // Updates: The individual achievement update requests. Updates []*AchievementUpdateRequest `json:"updates,omitempty"` }
type AchievementUpdateMultipleResponse ¶
type AchievementUpdateMultipleResponse struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementUpdateListResponse. Kind string `json:"kind,omitempty"` // UpdatedAchievements: The updated state of the achievements. UpdatedAchievements []*AchievementUpdateResponse `json:"updatedAchievements,omitempty"` }
type AchievementUpdateRequest ¶
type AchievementUpdateRequest struct { // AchievementId: The achievement this update is being applied to. AchievementId string `json:"achievementId,omitempty"` // IncrementPayload: The payload if an update of type INCREMENT was // requested for the achievement. IncrementPayload *GamesAchievementIncrement `json:"incrementPayload,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementUpdateRequest. Kind string `json:"kind,omitempty"` // SetStepsAtLeastPayload: The payload if an update of type // SET_STEPS_AT_LEAST was requested for the achievement. SetStepsAtLeastPayload *GamesAchievementSetStepsAtLeast `json:"setStepsAtLeastPayload,omitempty"` // UpdateType: The type of update being applied. // Possible values are: // // - "REVEAL" - Achievement is revealed. // - "UNLOCK" - Achievement is // unlocked. // - "INCREMENT" - Achievement is incremented. // - // "SET_STEPS_AT_LEAST" - Achievement progress is set to at least the // passed value. UpdateType string `json:"updateType,omitempty"` }
type AchievementUpdateResponse ¶
type AchievementUpdateResponse struct { // AchievementId: The achievement this update is was applied to. AchievementId string `json:"achievementId,omitempty"` // CurrentState: The current state of the achievement. // Possible values // are: // - "HIDDEN" - Achievement is hidden. // - "REVEALED" - // Achievement is revealed. // - "UNLOCKED" - Achievement is unlocked. CurrentState string `json:"currentState,omitempty"` // CurrentSteps: The current steps recorded for this achievement if it // is incremental. CurrentSteps int64 `json:"currentSteps,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#achievementUpdateResponse. Kind string `json:"kind,omitempty"` // NewlyUnlocked: Whether this achievement was newly unlocked (that is, // whether the unlock request for the achievement was the first for the // player). NewlyUnlocked bool `json:"newlyUnlocked,omitempty"` // UpdateOccurred: Whether the requested updates actually affected the // achievement. UpdateOccurred bool `json:"updateOccurred,omitempty"` }
type AchievementsIncrementCall ¶
type AchievementsIncrementCall struct {
// contains filtered or unexported fields
}
func (*AchievementsIncrementCall) Do ¶
func (c *AchievementsIncrementCall) Do() (*AchievementIncrementResponse, error)
func (*AchievementsIncrementCall) RequestId ¶
func (c *AchievementsIncrementCall) RequestId(requestId int64) *AchievementsIncrementCall
RequestId sets the optional parameter "requestId": A randomly generated numeric ID for each request specified by the caller. This number is used at the server to ensure that the request is handled correctly across retries.
type AchievementsListCall ¶
type AchievementsListCall struct {
// contains filtered or unexported fields
}
func (*AchievementsListCall) Do ¶
func (c *AchievementsListCall) Do() (*PlayerAchievementListResponse, error)
func (*AchievementsListCall) Language ¶
func (c *AchievementsListCall) Language(language string) *AchievementsListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*AchievementsListCall) MaxResults ¶
func (c *AchievementsListCall) MaxResults(maxResults int64) *AchievementsListCall
MaxResults sets the optional parameter "maxResults": The maximum number of achievement resources to return in the response, used for paging. For any response, the actual number of achievement resources returned may be less than the specified maxResults.
func (*AchievementsListCall) PageToken ¶
func (c *AchievementsListCall) PageToken(pageToken string) *AchievementsListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
func (*AchievementsListCall) State ¶
func (c *AchievementsListCall) State(state string) *AchievementsListCall
State sets the optional parameter "state": Tells the server to return only achievements with the specified state. If this parameter isn't specified, all achievements are returned.
type AchievementsRevealCall ¶
type AchievementsRevealCall struct {
// contains filtered or unexported fields
}
func (*AchievementsRevealCall) Do ¶
func (c *AchievementsRevealCall) Do() (*AchievementRevealResponse, error)
type AchievementsService ¶
type AchievementsService struct {
// contains filtered or unexported fields
}
func NewAchievementsService ¶
func NewAchievementsService(s *Service) *AchievementsService
func (*AchievementsService) Increment ¶
func (r *AchievementsService) Increment(achievementId string, stepsToIncrement int64) *AchievementsIncrementCall
Increment: Increments the steps of the achievement with the given ID for the currently authenticated player.
func (*AchievementsService) List ¶
func (r *AchievementsService) List(playerId string) *AchievementsListCall
List: Lists the progress for all your application's achievements for the currently authenticated player.
func (*AchievementsService) Reveal ¶
func (r *AchievementsService) Reveal(achievementId string) *AchievementsRevealCall
Reveal: Sets the state of the achievement with the given ID to REVEALED for the currently authenticated player.
func (*AchievementsService) SetStepsAtLeast ¶
func (r *AchievementsService) SetStepsAtLeast(achievementId string, steps int64) *AchievementsSetStepsAtLeastCall
SetStepsAtLeast: Sets the steps for the currently authenticated player towards unlocking an achievement. If the steps parameter is less than the current number of steps that the player already gained for the achievement, the achievement is not modified.
func (*AchievementsService) Unlock ¶
func (r *AchievementsService) Unlock(achievementId string) *AchievementsUnlockCall
Unlock: Unlocks this achievement for the currently authenticated player.
func (*AchievementsService) UpdateMultiple ¶
func (r *AchievementsService) UpdateMultiple(achievementupdatemultiplerequest *AchievementUpdateMultipleRequest) *AchievementsUpdateMultipleCall
UpdateMultiple: Updates multiple achievements for the currently authenticated player.
type AchievementsSetStepsAtLeastCall ¶
type AchievementsSetStepsAtLeastCall struct {
// contains filtered or unexported fields
}
func (*AchievementsSetStepsAtLeastCall) Do ¶
func (c *AchievementsSetStepsAtLeastCall) Do() (*AchievementSetStepsAtLeastResponse, error)
type AchievementsUnlockCall ¶
type AchievementsUnlockCall struct {
// contains filtered or unexported fields
}
func (*AchievementsUnlockCall) Do ¶
func (c *AchievementsUnlockCall) Do() (*AchievementUnlockResponse, error)
type AchievementsUpdateMultipleCall ¶
type AchievementsUpdateMultipleCall struct {
// contains filtered or unexported fields
}
func (*AchievementsUpdateMultipleCall) Do ¶
func (c *AchievementsUpdateMultipleCall) Do() (*AchievementUpdateMultipleResponse, error)
type AggregateStats ¶
type AggregateStats struct { // Count: The number of messages sent between a pair of peers. Count int64 `json:"count,omitempty,string"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#aggregateStats. Kind string `json:"kind,omitempty"` // Max: The maximum amount. Max int64 `json:"max,omitempty,string"` // Min: The minimum amount. Min int64 `json:"min,omitempty,string"` // Sum: The total number of bytes sent for messages between a pair of // peers. Sum int64 `json:"sum,omitempty,string"` }
type AnonymousPlayer ¶
type AnonymousPlayer struct { // AvatarImageUrl: The base URL for the image to display for the // anonymous player. AvatarImageUrl string `json:"avatarImageUrl,omitempty"` // DisplayName: The name to display for the anonymous player. DisplayName string `json:"displayName,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#anonymousPlayer. Kind string `json:"kind,omitempty"` }
type Application ¶
type Application struct { // Achievement_count: The number of achievements visible to the // currently authenticated player. Achievement_count int64 `json:"achievement_count,omitempty"` // Assets: The assets of the application. Assets []*ImageAsset `json:"assets,omitempty"` // Author: The author of the application. Author string `json:"author,omitempty"` // Category: The category of the application. Category *ApplicationCategory `json:"category,omitempty"` // Description: The description of the application. Description string `json:"description,omitempty"` // Id: The ID of the application. Id string `json:"id,omitempty"` // Instances: The instances of the application. Instances []*Instance `json:"instances,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#application. Kind string `json:"kind,omitempty"` // LastUpdatedTimestamp: The last updated timestamp of the application. LastUpdatedTimestamp int64 `json:"lastUpdatedTimestamp,omitempty,string"` // Leaderboard_count: The number of leaderboards visible to the // currently authenticated player. Leaderboard_count int64 `json:"leaderboard_count,omitempty"` // Name: The name of the application. Name string `json:"name,omitempty"` }
type ApplicationCategory ¶
type ApplicationCategory struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#applicationCategory. Kind string `json:"kind,omitempty"` // Primary: The primary category. Primary string `json:"primary,omitempty"` // Secondary: The secondary category. Secondary string `json:"secondary,omitempty"` }
type ApplicationsGetCall ¶
type ApplicationsGetCall struct {
// contains filtered or unexported fields
}
func (*ApplicationsGetCall) Do ¶
func (c *ApplicationsGetCall) Do() (*Application, error)
func (*ApplicationsGetCall) Language ¶
func (c *ApplicationsGetCall) Language(language string) *ApplicationsGetCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*ApplicationsGetCall) PlatformType ¶
func (c *ApplicationsGetCall) PlatformType(platformType string) *ApplicationsGetCall
PlatformType sets the optional parameter "platformType": Restrict application details returned to the specific platform.
type ApplicationsPlayedCall ¶
type ApplicationsPlayedCall struct {
// contains filtered or unexported fields
}
func (*ApplicationsPlayedCall) Do ¶
func (c *ApplicationsPlayedCall) Do() error
type ApplicationsService ¶
type ApplicationsService struct {
// contains filtered or unexported fields
}
func NewApplicationsService ¶
func NewApplicationsService(s *Service) *ApplicationsService
func (*ApplicationsService) Get ¶
func (r *ApplicationsService) Get(applicationId string) *ApplicationsGetCall
Get: Retrieves the metadata of the application with the given ID. If the requested application is not available for the specified platformType, the returned response will not include any instance data.
func (*ApplicationsService) Played ¶
func (r *ApplicationsService) Played() *ApplicationsPlayedCall
Played: Indicate that the the currently authenticated user is playing your application.
type GamesAchievementIncrement ¶
type GamesAchievementIncrement struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#GamesAchievementIncrement. Kind string `json:"kind,omitempty"` // RequestId: The requestId associated with an increment to an // achievement. RequestId int64 `json:"requestId,omitempty,string"` // Steps: The number of steps to be incremented. Steps int64 `json:"steps,omitempty"` }
type GamesAchievementSetStepsAtLeast ¶
type GamesAchievementSetStepsAtLeast struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#GamesAchievementSetStepsAtLeast. Kind string `json:"kind,omitempty"` // Steps: The minimum number of steps for the achievement to be set to. Steps int64 `json:"steps,omitempty"` }
type ImageAsset ¶
type ImageAsset struct { // Height: The height of the asset. Height int64 `json:"height,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#imageAsset. Kind string `json:"kind,omitempty"` // Name: The name of the asset. Name string `json:"name,omitempty"` // Url: The URL of the asset. Url string `json:"url,omitempty"` // Width: The width of the asset. Width int64 `json:"width,omitempty"` }
type Instance ¶
type Instance struct { // AcquisitionUri: URI which shows where a user can acquire this // instance. AcquisitionUri string `json:"acquisitionUri,omitempty"` // AndroidInstance: Platform dependent details for Android. AndroidInstance *InstanceAndroidDetails `json:"androidInstance,omitempty"` // IosInstance: Platform dependent details for iOS. IosInstance *InstanceIosDetails `json:"iosInstance,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#instance. Kind string `json:"kind,omitempty"` // Name: Localized display name. Name string `json:"name,omitempty"` // PlatformType: The platform type. // Possible values are: // - "ANDROID" - // Instance is for Android. // - "IOS" - Instance is for iOS // - "WEB_APP" // - Instance is for Web App. PlatformType string `json:"platformType,omitempty"` // RealtimePlay: Flag to show if this game instance supports realtime // play. RealtimePlay bool `json:"realtimePlay,omitempty"` // TurnBasedPlay: Flag to show if this game instance supports turn based // play. TurnBasedPlay bool `json:"turnBasedPlay,omitempty"` // WebInstance: Platform dependent details for Web. WebInstance *InstanceWebDetails `json:"webInstance,omitempty"` }
type InstanceAndroidDetails ¶
type InstanceAndroidDetails struct { // EnablePiracyCheck: Flag indicating whether the anti-piracy check is // enabled. EnablePiracyCheck bool `json:"enablePiracyCheck,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#instanceAndroidDetails. Kind string `json:"kind,omitempty"` // PackageName: Android package name which maps to Google Play URL. PackageName string `json:"packageName,omitempty"` // Preferred: Indicates that this instance is the default for new // installations. Preferred bool `json:"preferred,omitempty"` }
type InstanceIosDetails ¶
type InstanceIosDetails struct { // BundleIdentifier: Bundle identifier. BundleIdentifier string `json:"bundleIdentifier,omitempty"` // ItunesAppId: iTunes App ID. ItunesAppId string `json:"itunesAppId,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#instanceIosDetails. Kind string `json:"kind,omitempty"` // PreferredForIpad: Indicates that this instance is the default for new // installations on iPad devices. PreferredForIpad bool `json:"preferredForIpad,omitempty"` // PreferredForIphone: Indicates that this instance is the default for // new installations on iPhone devices. PreferredForIphone bool `json:"preferredForIphone,omitempty"` // SupportIpad: Flag to indicate if this instance supports iPad. SupportIpad bool `json:"supportIpad,omitempty"` // SupportIphone: Flag to indicate if this instance supports iPhone. SupportIphone bool `json:"supportIphone,omitempty"` }
type InstanceWebDetails ¶
type InstanceWebDetails struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#instanceWebDetails. Kind string `json:"kind,omitempty"` // LaunchUrl: Launch URL for the game. LaunchUrl string `json:"launchUrl,omitempty"` // Preferred: Indicates that this instance is the default for new // installations. Preferred bool `json:"preferred,omitempty"` }
type Leaderboard ¶
type Leaderboard struct { // IconUrl: The icon for the leaderboard. IconUrl string `json:"iconUrl,omitempty"` // Id: The leaderboard ID. Id string `json:"id,omitempty"` // IsIconUrlDefault: Indicates whether the icon image being returned is // a default image, or is game-provided. IsIconUrlDefault bool `json:"isIconUrlDefault,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#leaderboard. Kind string `json:"kind,omitempty"` // Name: The name of the leaderboard. Name string `json:"name,omitempty"` // Order: How scores are ordered. // Possible values are: // - // "LARGER_IS_BETTER" - Larger values are better; scores are sorted in // descending order. // - "SMALLER_IS_BETTER" - Smaller values are better; // scores are sorted in ascending order. Order string `json:"order,omitempty"` }
type LeaderboardEntry ¶
type LeaderboardEntry struct { // FormattedScore: The localized string for the numerical value of this // score. FormattedScore string `json:"formattedScore,omitempty"` // FormattedScoreRank: The localized string for the rank of this score // for this leaderboard. FormattedScoreRank string `json:"formattedScoreRank,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#leaderboardEntry. Kind string `json:"kind,omitempty"` // Player: The player who holds this score. Player *Player `json:"player,omitempty"` // ScoreRank: The rank of this score for this leaderboard. ScoreRank int64 `json:"scoreRank,omitempty,string"` // ScoreTag: Additional information about the score. Values must contain // no more than 64 URI-safe characters as defined by section 2.3 of RFC // 3986. ScoreTag string `json:"scoreTag,omitempty"` // ScoreValue: The numerical value of this score. ScoreValue int64 `json:"scoreValue,omitempty,string"` // TimeSpan: The time span of this high score. // Possible values are: // - // "ALL_TIME" - The score is an all-time high score. // - "WEEKLY" - The // score is a weekly high score. // - "DAILY" - The score is a daily high // score. TimeSpan string `json:"timeSpan,omitempty"` // WriteTimestampMillis: The timestamp at which this score was recorded, // in milliseconds since the epoch in UTC. WriteTimestampMillis int64 `json:"writeTimestampMillis,omitempty,string"` }
type LeaderboardListResponse ¶
type LeaderboardListResponse struct { // Items: The leaderboards. Items []*Leaderboard `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#leaderboardListResponse. Kind string `json:"kind,omitempty"` // NextPageToken: Token corresponding to the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type LeaderboardScoreRank ¶
type LeaderboardScoreRank struct { // FormattedNumScores: The number of scores in the leaderboard as a // string. FormattedNumScores string `json:"formattedNumScores,omitempty"` // FormattedRank: The rank in the leaderboard as a string. FormattedRank string `json:"formattedRank,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#leaderboardScoreRank. Kind string `json:"kind,omitempty"` // NumScores: The number of scores in the leaderboard. NumScores int64 `json:"numScores,omitempty,string"` // Rank: The rank in the leaderboard. Rank int64 `json:"rank,omitempty,string"` }
type LeaderboardScores ¶
type LeaderboardScores struct { // Items: The scores in the leaderboard. Items []*LeaderboardEntry `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#leaderboardScores. Kind string `json:"kind,omitempty"` // NextPageToken: The pagination token for the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` // NumScores: The total number of scores in the leaderboard. NumScores int64 `json:"numScores,omitempty,string"` // PlayerScore: The score of the requesting player on the leaderboard. // The player's score may appear both here and in the list of scores // above. If you are viewing a public leaderboard and the player is not // sharing their gameplay information publicly, the scoreRank and // formattedScoreRank values will not be present. PlayerScore *LeaderboardEntry `json:"playerScore,omitempty"` // PrevPageToken: The pagination token for the previous page of results. PrevPageToken string `json:"prevPageToken,omitempty"` }
type LeaderboardsGetCall ¶
type LeaderboardsGetCall struct {
// contains filtered or unexported fields
}
func (*LeaderboardsGetCall) Do ¶
func (c *LeaderboardsGetCall) Do() (*Leaderboard, error)
func (*LeaderboardsGetCall) Language ¶
func (c *LeaderboardsGetCall) Language(language string) *LeaderboardsGetCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type LeaderboardsListCall ¶
type LeaderboardsListCall struct {
// contains filtered or unexported fields
}
func (*LeaderboardsListCall) Do ¶
func (c *LeaderboardsListCall) Do() (*LeaderboardListResponse, error)
func (*LeaderboardsListCall) Language ¶
func (c *LeaderboardsListCall) Language(language string) *LeaderboardsListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*LeaderboardsListCall) MaxResults ¶
func (c *LeaderboardsListCall) MaxResults(maxResults int64) *LeaderboardsListCall
MaxResults sets the optional parameter "maxResults": The maximum number of leaderboards to return in the response. For any response, the actual number of leaderboards returned may be less than the specified maxResults.
func (*LeaderboardsListCall) PageToken ¶
func (c *LeaderboardsListCall) PageToken(pageToken string) *LeaderboardsListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type LeaderboardsService ¶
type LeaderboardsService struct {
// contains filtered or unexported fields
}
func NewLeaderboardsService ¶
func NewLeaderboardsService(s *Service) *LeaderboardsService
func (*LeaderboardsService) Get ¶
func (r *LeaderboardsService) Get(leaderboardId string) *LeaderboardsGetCall
Get: Retrieves the metadata of the leaderboard with the given ID.
func (*LeaderboardsService) List ¶
func (r *LeaderboardsService) List() *LeaderboardsListCall
List: Lists all the leaderboard metadata for your application.
type NetworkDiagnostics ¶
type NetworkDiagnostics struct { // AndroidNetworkSubtype: The Android network subtype. AndroidNetworkSubtype int64 `json:"androidNetworkSubtype,omitempty"` // AndroidNetworkType: The Android network type. AndroidNetworkType int64 `json:"androidNetworkType,omitempty"` // IosNetworkType: iOS network type as defined in Reachability.h. IosNetworkType int64 `json:"iosNetworkType,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#networkDiagnostics. Kind string `json:"kind,omitempty"` // RegistrationLatencyMillis: The amount of time in milliseconds it took // for the client to establish a connection with the XMPP server. RegistrationLatencyMillis int64 `json:"registrationLatencyMillis,omitempty"` }
type ParticipantResult ¶
type ParticipantResult struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#participantResult. Kind string `json:"kind,omitempty"` // ParticipantId: The ID of the participant. ParticipantId string `json:"participantId,omitempty"` // Placing: The placement or ranking of the participant in the match // results; a number from one to the number of participants in the // match. Multiple participants may have the same placing value in case // of a type. Placing int64 `json:"placing,omitempty"` // Result: The result of the participant for this match. // Possible values // are: // - "MATCH_RESULT_WIN" - The participant won the match. // - // "MATCH_RESULT_LOSS" - The participant lost the match. // - // "MATCH_RESULT_TIE" - The participant tied the match. // - // "MATCH_RESULT_NONE" - There was no winner for the match (nobody wins // or loses this kind of game.) // - "MATCH_RESULT_DISCONNECT" - The // participant disconnected / left during the match. // - // "MATCH_RESULT_DISAGREED" - Different clients reported different // results for this participant. Result string `json:"result,omitempty"` }
type PeerChannelDiagnostics ¶
type PeerChannelDiagnostics struct { // BytesReceived: Number of bytes received. BytesReceived *AggregateStats `json:"bytesReceived,omitempty"` // BytesSent: Number of bytes sent. BytesSent *AggregateStats `json:"bytesSent,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#peerChannelDiagnostics. Kind string `json:"kind,omitempty"` // NumMessagesLost: Number of messages lost. NumMessagesLost int64 `json:"numMessagesLost,omitempty"` // NumMessagesReceived: Number of messages received. NumMessagesReceived int64 `json:"numMessagesReceived,omitempty"` // NumMessagesSent: Number of messages sent. NumMessagesSent int64 `json:"numMessagesSent,omitempty"` // NumSendFailures: Number of send failures. NumSendFailures int64 `json:"numSendFailures,omitempty"` // RoundtripLatencyMillis: Roundtrip latency stats in milliseconds. RoundtripLatencyMillis *AggregateStats `json:"roundtripLatencyMillis,omitempty"` }
type PeerSessionDiagnostics ¶
type PeerSessionDiagnostics struct { // ConnectedTimestampMillis: Connected time in milliseconds. ConnectedTimestampMillis int64 `json:"connectedTimestampMillis,omitempty,string"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#peerSessionDiagnostics. Kind string `json:"kind,omitempty"` // ParticipantId: The participant ID of the peer. ParticipantId string `json:"participantId,omitempty"` // ReliableChannel: Reliable channel diagnostics. ReliableChannel *PeerChannelDiagnostics `json:"reliableChannel,omitempty"` // UnreliableChannel: Unreliable channel diagnostics. UnreliableChannel *PeerChannelDiagnostics `json:"unreliableChannel,omitempty"` }
type Played ¶
type Played struct { // AutoMatched: True if the player was auto-matched with the currently // authenticated user. AutoMatched bool `json:"autoMatched,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#played. Kind string `json:"kind,omitempty"` // TimeMillis: The last time the player played the game in milliseconds // since the epoch in UTC. TimeMillis int64 `json:"timeMillis,omitempty,string"` }
type Player ¶
type Player struct { // AvatarImageUrl: The base URL for the image that represents the // player. AvatarImageUrl string `json:"avatarImageUrl,omitempty"` // DisplayName: The name to display for the player. DisplayName string `json:"displayName,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#player. Kind string `json:"kind,omitempty"` // LastPlayedWith: Details about the last time this player played a // multiplayer game with the currently authenticated player. Populated // for PLAYED_WITH player collection members. LastPlayedWith *Played `json:"lastPlayedWith,omitempty"` // Name: An object representation of the individual components of the // player's name. Name *PlayerName `json:"name,omitempty"` // PlayerId: The ID of the player. PlayerId string `json:"playerId,omitempty"` }
type PlayerAchievement ¶
type PlayerAchievement struct { // AchievementState: The state of the achievement. // Possible values are: // // - "HIDDEN" - Achievement is hidden. // - "REVEALED" - Achievement is // revealed. // - "UNLOCKED" - Achievement is unlocked. AchievementState string `json:"achievementState,omitempty"` // CurrentSteps: The current steps for an incremental achievement. CurrentSteps int64 `json:"currentSteps,omitempty"` // FormattedCurrentStepsString: The current steps for an incremental // achievement as a string. FormattedCurrentStepsString string `json:"formattedCurrentStepsString,omitempty"` // Id: The ID of the achievement. Id string `json:"id,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerAchievement. Kind string `json:"kind,omitempty"` // LastUpdatedTimestamp: The timestamp of the last modification to this // achievement's state. LastUpdatedTimestamp int64 `json:"lastUpdatedTimestamp,omitempty,string"` }
type PlayerAchievementListResponse ¶
type PlayerAchievementListResponse struct { // Items: The achievements. Items []*PlayerAchievement `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerAchievementListResponse. Kind string `json:"kind,omitempty"` // NextPageToken: Token corresponding to the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type PlayerLeaderboardScore ¶
type PlayerLeaderboardScore struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerLeaderboardScore. Kind string `json:"kind,omitempty"` // Leaderboard_id: The ID of the leaderboard this score is in. Leaderboard_id string `json:"leaderboard_id,omitempty"` // PublicRank: The public rank of the score in this leaderboard. This // object will not be present if the user is not sharing their scores // publicly. PublicRank *LeaderboardScoreRank `json:"publicRank,omitempty"` // ScoreString: The formatted value of this score. ScoreString string `json:"scoreString,omitempty"` // ScoreTag: Additional information about the score. Values must contain // no more than 64 URI-safe characters as defined by section 2.3 of RFC // 3986. ScoreTag string `json:"scoreTag,omitempty"` // ScoreValue: The numerical value of this score. ScoreValue int64 `json:"scoreValue,omitempty,string"` // SocialRank: The social rank of the score in this leaderboard. SocialRank *LeaderboardScoreRank `json:"socialRank,omitempty"` // TimeSpan: The time span of this score. // Possible values are: // - // "ALL_TIME" - The score is an all-time score. // - "WEEKLY" - The score // is a weekly score. // - "DAILY" - The score is a daily score. TimeSpan string `json:"timeSpan,omitempty"` // WriteTimestamp: The timestamp at which this score was recorded, in // milliseconds since the epoch in UTC. WriteTimestamp int64 `json:"writeTimestamp,omitempty,string"` }
type PlayerLeaderboardScoreListResponse ¶
type PlayerLeaderboardScoreListResponse struct { // Items: The leaderboard scores. Items []*PlayerLeaderboardScore `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerLeaderboardScoreListResponse. Kind string `json:"kind,omitempty"` // NextPageToken: The pagination token for the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` // Player: The Player resources for the owner of this score. Player *Player `json:"player,omitempty"` }
type PlayerListResponse ¶
type PlayerListResponse struct { // Items: The players. Items []*Player `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerListResponse. Kind string `json:"kind,omitempty"` // NextPageToken: Token corresponding to the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type PlayerName ¶
type PlayerScore ¶
type PlayerScore struct { // FormattedScore: The formatted score for this player score. FormattedScore string `json:"formattedScore,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerScore. Kind string `json:"kind,omitempty"` // Score: The numerical value for this player score. Score int64 `json:"score,omitempty,string"` // ScoreTag: Additional information about this score. Values will // contain no more than 64 URI-safe characters as defined by section 2.3 // of RFC 3986. ScoreTag string `json:"scoreTag,omitempty"` // TimeSpan: The time span for this player score. // Possible values are: // // - "ALL_TIME" - The score is an all-time score. // - "WEEKLY" - The // score is a weekly score. // - "DAILY" - The score is a daily score. TimeSpan string `json:"timeSpan,omitempty"` }
type PlayerScoreListResponse ¶
type PlayerScoreListResponse struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerScoreListResponse. Kind string `json:"kind,omitempty"` // SubmittedScores: The score submissions statuses. SubmittedScores []*PlayerScoreResponse `json:"submittedScores,omitempty"` }
type PlayerScoreResponse ¶
type PlayerScoreResponse struct { // BeatenScoreTimeSpans: The time spans where the submitted score is // better than the existing score for that time span. // Possible values // are: // - "ALL_TIME" - The score is an all-time score. // - "WEEKLY" - // The score is a weekly score. // - "DAILY" - The score is a daily score. BeatenScoreTimeSpans []string `json:"beatenScoreTimeSpans,omitempty"` // FormattedScore: The formatted value of the submitted score. FormattedScore string `json:"formattedScore,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerScoreResponse. Kind string `json:"kind,omitempty"` // LeaderboardId: The leaderboard ID that this score was submitted to. LeaderboardId string `json:"leaderboardId,omitempty"` // ScoreTag: Additional information about this score. Values will // contain no more than 64 URI-safe characters as defined by section 2.3 // of RFC 3986. ScoreTag string `json:"scoreTag,omitempty"` // UnbeatenScores: The scores in time spans that have not been beaten. // As an example, the submitted score may be better than the player's // DAILY score, but not better than the player's scores for the WEEKLY // or ALL_TIME time spans. UnbeatenScores []*PlayerScore `json:"unbeatenScores,omitempty"` }
type PlayerScoreSubmissionList ¶
type PlayerScoreSubmissionList struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#playerScoreSubmissionList. Kind string `json:"kind,omitempty"` // Scores: The score submissions. Scores []*ScoreSubmission `json:"scores,omitempty"` }
type PlayersGetCall ¶
type PlayersGetCall struct {
// contains filtered or unexported fields
}
func (*PlayersGetCall) Do ¶
func (c *PlayersGetCall) Do() (*Player, error)
type PlayersListCall ¶
type PlayersListCall struct {
// contains filtered or unexported fields
}
func (*PlayersListCall) Do ¶
func (c *PlayersListCall) Do() (*PlayerListResponse, error)
func (*PlayersListCall) MaxResults ¶
func (c *PlayersListCall) MaxResults(maxResults int64) *PlayersListCall
MaxResults sets the optional parameter "maxResults": The maximum number of player resources to return in the response, used for paging. For any response, the actual number of player resources returned may be less than the specified maxResults.
func (*PlayersListCall) PageToken ¶
func (c *PlayersListCall) PageToken(pageToken string) *PlayersListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type PlayersService ¶
type PlayersService struct {
// contains filtered or unexported fields
}
func NewPlayersService ¶
func NewPlayersService(s *Service) *PlayersService
func (*PlayersService) Get ¶
func (r *PlayersService) Get(playerId string) *PlayersGetCall
Get: Retrieves the Player resource with the given ID. To retrieve the player for the currently authenticated user, set playerId to me.
func (*PlayersService) List ¶
func (r *PlayersService) List(collection string) *PlayersListCall
List: Get the collection of players for the currently authenticated user.
type PushToken ¶
type PushToken struct { // ClientRevision: The revision of the client SDK used by your // application, in the same format that's used by revisions.check. Used // to send backward compatible messages. Format: // [PLATFORM_TYPE]:[VERSION_NUMBER]. Possible values of PLATFORM_TYPE // are: // - IOS - Push token is for iOS ClientRevision string `json:"clientRevision,omitempty"` // Id: Unique identifier for this push token. Id *PushTokenId `json:"id,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#pushToken. Kind string `json:"kind,omitempty"` // Language: The preferred language for notifications that are sent // using this token. Language string `json:"language,omitempty"` }
type PushTokenId ¶
type PushTokenId struct { // Ios: A push token ID for iOS devices. Ios *PushTokenIdIos `json:"ios,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#pushTokenId. Kind string `json:"kind,omitempty"` }
type PushTokenIdIos ¶
type PushTokenIdIos struct { // Apns_device_token: Device token supplied by an iOS system call to // register for remote notifications. Encode this field as web-safe // base64. Apns_device_token string `json:"apns_device_token,omitempty"` // Apns_environment: Use SANDBOX during development for the APNS test // server at gateway.sandbox.push.apple.com or PRODUCTION for the // production server at gateway.push.apple.com. Apns_environment string `json:"apns_environment,omitempty"` }
type PushtokensRemoveCall ¶
type PushtokensRemoveCall struct {
// contains filtered or unexported fields
}
func (*PushtokensRemoveCall) Do ¶
func (c *PushtokensRemoveCall) Do() error
type PushtokensService ¶
type PushtokensService struct {
// contains filtered or unexported fields
}
func NewPushtokensService ¶
func NewPushtokensService(s *Service) *PushtokensService
func (*PushtokensService) Remove ¶
func (r *PushtokensService) Remove(pushtokenid *PushTokenId) *PushtokensRemoveCall
Remove: Removes a push token for the current user and application. Removing a non-existent push token will report success.
func (*PushtokensService) Update ¶
func (r *PushtokensService) Update(pushtoken *PushToken) *PushtokensUpdateCall
Update: Registers a push token for the current user and application.
type PushtokensUpdateCall ¶
type PushtokensUpdateCall struct {
// contains filtered or unexported fields
}
func (*PushtokensUpdateCall) Do ¶
func (c *PushtokensUpdateCall) Do() error
type RevisionCheckResponse ¶
type RevisionCheckResponse struct { // ApiVersion: The version of the API this client revision should use // when calling API methods. ApiVersion string `json:"apiVersion,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#revisionCheckResponse. Kind string `json:"kind,omitempty"` // RevisionStatus: The result of the revision check. // Possible values // are: // - "OK" - The revision being used is current. // - "DEPRECATED" - // There is currently a newer version available, but the revision being // used still works. // - "INVALID" - The revision being used is not // supported in any released version. RevisionStatus string `json:"revisionStatus,omitempty"` }
type RevisionsCheckCall ¶
type RevisionsCheckCall struct {
// contains filtered or unexported fields
}
func (*RevisionsCheckCall) Do ¶
func (c *RevisionsCheckCall) Do() (*RevisionCheckResponse, error)
type RevisionsService ¶
type RevisionsService struct {
// contains filtered or unexported fields
}
func NewRevisionsService ¶
func NewRevisionsService(s *Service) *RevisionsService
func (*RevisionsService) Check ¶
func (r *RevisionsService) Check(clientRevision string) *RevisionsCheckCall
Check: Checks whether the games client is out of date.
type Room ¶
type Room struct { // ApplicationId: The ID of the application being played. ApplicationId string `json:"applicationId,omitempty"` // AutoMatchingCriteria: Criteria for auto-matching players into this // room. AutoMatchingCriteria *RoomAutoMatchingCriteria `json:"autoMatchingCriteria,omitempty"` // AutoMatchingStatus: Auto-matching status for this room. Not set if // the room is not currently in the auto-matching queue. AutoMatchingStatus *RoomAutoMatchStatus `json:"autoMatchingStatus,omitempty"` // CreationDetails: Details about the room creation. CreationDetails *RoomModification `json:"creationDetails,omitempty"` // Description: 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.) Description string `json:"description,omitempty"` // InviterId: The ID of the participant that invited the user to the // room. Not set if the user was not invited to the room. InviterId string `json:"inviterId,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#room. Kind string `json:"kind,omitempty"` // LastUpdateDetails: Details about the last update to the room. LastUpdateDetails *RoomModification `json:"lastUpdateDetails,omitempty"` // Participants: The participants involved in the room, along with their // statuses. Includes participants who have left or declined // invitations. Participants []*RoomParticipant `json:"participants,omitempty"` // RoomId: Globally unique ID for a room. RoomId string `json:"roomId,omitempty"` // RoomStatusVersion: The version of the room status: an increasing // counter, used by the client to ignore out-of-order updates to room // status. RoomStatusVersion int64 `json:"roomStatusVersion,omitempty"` // Status: The status of the room. // Possible values are: // - // "ROOM_INVITING" - One or more players have been invited and not // responded. // - "ROOM_AUTO_MATCHING" - One or more slots need to be // filled by auto-matching. // - "ROOM_CONNECTING" - Players have joined // and are connecting to each other (either before or after // auto-matching). // - "ROOM_ACTIVE" - All players have joined and // connected to each other. // - "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. Status string `json:"status,omitempty"` // Variant: The variant / mode of the application being played; can be // any integer value, or left blank. Variant int64 `json:"variant,omitempty"` }
type RoomAutoMatchStatus ¶
type RoomAutoMatchStatus struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomAutoMatchStatus. Kind string `json:"kind,omitempty"` // WaitEstimateSeconds: An estimate for the amount of time (in seconds) // that auto-matching is expected to take to complete. WaitEstimateSeconds int64 `json:"waitEstimateSeconds,omitempty"` }
type RoomAutoMatchingCriteria ¶
type RoomAutoMatchingCriteria struct { // ExclusiveBitmask: 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. ExclusiveBitmask int64 `json:"exclusiveBitmask,omitempty,string"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomAutoMatchingCriteria. Kind string `json:"kind,omitempty"` // MaxAutoMatchingPlayers: The maximum number of players that should be // added to the room by auto-matching. MaxAutoMatchingPlayers int64 `json:"maxAutoMatchingPlayers,omitempty"` // MinAutoMatchingPlayers: The minimum number of players that should be // added to the room by auto-matching. MinAutoMatchingPlayers int64 `json:"minAutoMatchingPlayers,omitempty"` }
type RoomClientAddress ¶
type RoomClientAddress struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomClientAddress. Kind string `json:"kind,omitempty"` // XmppAddress: The XMPP address of the client on the Google Games XMPP // network. XmppAddress string `json:"xmppAddress,omitempty"` }
type RoomCreateRequest ¶
type RoomCreateRequest struct { // AutoMatchingCriteria: Criteria for auto-matching players into this // room. AutoMatchingCriteria *RoomAutoMatchingCriteria `json:"autoMatchingCriteria,omitempty"` // Capabilities: The capabilities that this client supports for realtime // communication. Capabilities []string `json:"capabilities,omitempty"` // ClientAddress: Client address for the player creating the room. ClientAddress *RoomClientAddress `json:"clientAddress,omitempty"` // InvitedPlayerIds: The player IDs to invite to the room. InvitedPlayerIds []string `json:"invitedPlayerIds,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomCreateRequest. Kind string `json:"kind,omitempty"` // NetworkDiagnostics: Network diagnostics for the client creating the // room. NetworkDiagnostics *NetworkDiagnostics `json:"networkDiagnostics,omitempty"` // RequestId: A randomly generated numeric ID. This number is used at // the server to ensure that the request is handled correctly across // retries. RequestId int64 `json:"requestId,omitempty,string"` // Variant: 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. Variant int64 `json:"variant,omitempty"` }
type RoomJoinRequest ¶
type RoomJoinRequest struct { // Capabilities: The capabilities that this client supports for realtime // communication. Capabilities []string `json:"capabilities,omitempty"` // ClientAddress: Client address for the player joining the room. ClientAddress *RoomClientAddress `json:"clientAddress,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomJoinRequest. Kind string `json:"kind,omitempty"` // NetworkDiagnostics: Network diagnostics for the client joining the // room. NetworkDiagnostics *NetworkDiagnostics `json:"networkDiagnostics,omitempty"` }
type RoomLeaveDiagnostics ¶
type RoomLeaveDiagnostics struct { // AndroidNetworkSubtype: Android network subtype. // http://developer.android.com/reference/android/net/NetworkInfo.html#ge // tSubtype() AndroidNetworkSubtype int64 `json:"androidNetworkSubtype,omitempty"` // AndroidNetworkType: Android network type. // http://developer.android.com/reference/android/net/NetworkInfo.html#ge // tType() AndroidNetworkType int64 `json:"androidNetworkType,omitempty"` // IosNetworkType: iOS network type as defined in Reachability.h. IosNetworkType int64 `json:"iosNetworkType,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomLeaveDiagnostics. Kind string `json:"kind,omitempty"` // PeerSession: Diagnostics about all peer sessions. PeerSession []*PeerSessionDiagnostics `json:"peerSession,omitempty"` // SocketsUsed: Whether or not sockets were used. SocketsUsed bool `json:"socketsUsed,omitempty"` }
type RoomLeaveRequest ¶
type RoomLeaveRequest struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomLeaveRequest. Kind string `json:"kind,omitempty"` // LeaveDiagnostics: Diagnostics for a player leaving the room. LeaveDiagnostics *RoomLeaveDiagnostics `json:"leaveDiagnostics,omitempty"` // Reason: Reason for leaving the match. // Possible values are: // - // "PLAYER_LEFT" - The player chose to leave the room.. // - "GAME_LEFT" - // The game chose to remove the player from the room. // - // "REALTIME_ABANDONED" - The player switched to another application and // abandoned the room. // - "REALTIME_PEER_CONNECTION_FAILURE" - The // client was unable to establish a connection to other peer(s). // - // "REALTIME_SERVER_CONNECTION_FAILURE" - The client was unable to // communicate with the server. // - "REALTIME_SERVER_ERROR" - The client // received an error response when it tried to communicate with the // server. // - "REALTIME_TIMEOUT" - The client timed out while waiting // for a room. Reason string `json:"reason,omitempty"` }
type RoomList ¶
type RoomList struct { // Items: The rooms. Items []*Room `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomList. Kind string `json:"kind,omitempty"` // NextPageToken: The pagination token for the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type RoomModification ¶
type RoomModification struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomModification. Kind string `json:"kind,omitempty"` // ModifiedTimestampMillis: The timestamp at which they modified the // room, in milliseconds since the epoch in UTC. ModifiedTimestampMillis int64 `json:"modifiedTimestampMillis,omitempty,string"` // ParticipantId: The ID of the participant that modified the room. ParticipantId string `json:"participantId,omitempty"` }
type RoomP2PStatus ¶
type RoomP2PStatus struct { // ConnectionSetupLatencyMillis: The amount of time in milliseconds it // took to establish connections with this peer. ConnectionSetupLatencyMillis int64 `json:"connectionSetupLatencyMillis,omitempty"` // Error: The error code in event of a failure. // Possible values are: // - // "P2P_FAILED" - The client failed to establish a P2P connection with // the peer. // - "PRESENCE_FAILED" - The client failed to register to // receive P2P connections. // - "RELAY_SERVER_FAILED" - The client // received an error when trying to use the relay server to establish a // P2P connection with the peer. Error string `json:"error,omitempty"` // Error_reason: More detailed diagnostic message returned in event of a // failure. Error_reason string `json:"error_reason,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomP2PStatus. Kind string `json:"kind,omitempty"` // ParticipantId: The ID of the participant. ParticipantId string `json:"participantId,omitempty"` // Status: The status of the peer in the room. // Possible values are: // - // "CONNECTION_ESTABLISHED" - The client established a P2P connection // with the peer. // - "CONNECTION_FAILED" - The client failed to // establish directed presence with the peer. Status string `json:"status,omitempty"` // UnreliableRoundtripLatencyMillis: The amount of time in milliseconds // it took to send packets back and forth on the unreliable channel with // this peer. UnreliableRoundtripLatencyMillis int64 `json:"unreliableRoundtripLatencyMillis,omitempty"` }
type RoomP2PStatuses ¶
type RoomP2PStatuses struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomP2PStatuses. Kind string `json:"kind,omitempty"` // Updates: The updates for the peers. Updates []*RoomP2PStatus `json:"updates,omitempty"` }
type RoomParticipant ¶
type RoomParticipant struct { // AutoMatched: True if this participant was auto-matched with the // requesting player. AutoMatched bool `json:"autoMatched,omitempty"` // AutoMatchedPlayer: Information about a player that has been // anonymously auto-matched against the requesting player. (Either // player or autoMatchedPlayer will be set.) AutoMatchedPlayer *AnonymousPlayer `json:"autoMatchedPlayer,omitempty"` // Capabilities: The capabilities which can be used when communicating // with this participant. Capabilities []string `json:"capabilities,omitempty"` // ClientAddress: Client address for the participant. ClientAddress *RoomClientAddress `json:"clientAddress,omitempty"` // Connected: True if this participant is in the fully connected set of // peers in the room. Connected bool `json:"connected,omitempty"` // Id: An identifier for the participant in the scope of the room. // Cannot be used to identify a player across rooms or in other // contexts. Id string `json:"id,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomParticipant. Kind string `json:"kind,omitempty"` // LeaveReason: The reason the participant left the room; populated if // the participant status is PARTICIPANT_LEFT. // Possible values are: // - // "PLAYER_LEFT" - The player explicitly chose to leave the room. // - // "GAME_LEFT" - The game chose to remove the player from the room. // - // "ABANDONED" - The player switched to another application and // abandoned the room. // - "PEER_CONNECTION_FAILURE" - The client was // unable to establish or maintain a connection to other peer(s) in the // room. // - "SERVER_ERROR" - The client received an error response when // it tried to communicate with the server. // - "TIMEOUT" - The client // timed out while waiting for players to join and connect. // - // "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly. LeaveReason string `json:"leaveReason,omitempty"` // Player: Information about the player. Not populated if this player // was anonymously auto-matched against the requesting player. (Either // player or autoMatchedPlayer will be set.) Player *Player `json:"player,omitempty"` // Status: The status of the participant with respect to the // room. // Possible values are: // - "PARTICIPANT_INVITED" - The // participant has been invited to join the room, but has not yet // responded. // - "PARTICIPANT_JOINED" - The participant has joined the // room (either after creating it or accepting an invitation.) // - // "PARTICIPANT_DECLINED" - The participant declined an invitation to // join the room. // - "PARTICIPANT_LEFT" - The participant joined the // room and then left it. Status string `json:"status,omitempty"` }
type RoomStatus ¶
type RoomStatus struct { // AutoMatchingStatus: Auto-matching status for this room. Not set if // the room is not currently in the automatching queue. AutoMatchingStatus *RoomAutoMatchStatus `json:"autoMatchingStatus,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#roomStatus. Kind string `json:"kind,omitempty"` // Participants: The participants involved in the room, along with their // statuses. Includes participants who have left or declined // invitations. Participants []*RoomParticipant `json:"participants,omitempty"` // RoomId: Globally unique ID for a room. RoomId string `json:"roomId,omitempty"` // Status: The status of the room. // Possible values are: // - // "ROOM_INVITING" - One or more players have been invited and not // responded. // - "ROOM_AUTO_MATCHING" - One or more slots need to be // filled by auto-matching. // - "ROOM_CONNECTING" - Players have joined // are connecting to each other (either before or after auto-matching). // // - "ROOM_ACTIVE" - All players have joined and connected to each // other. // - "ROOM_DELETED" - All joined players have left. Status string `json:"status,omitempty"` // StatusVersion: The version of the status for the room: an increasing // counter, used by the client to ignore out-of-order updates to room // status. StatusVersion int64 `json:"statusVersion,omitempty"` }
type RoomsCreateCall ¶
type RoomsCreateCall struct {
// contains filtered or unexported fields
}
func (*RoomsCreateCall) Do ¶
func (c *RoomsCreateCall) Do() (*Room, error)
func (*RoomsCreateCall) Language ¶
func (c *RoomsCreateCall) Language(language string) *RoomsCreateCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type RoomsDeclineCall ¶
type RoomsDeclineCall struct {
// contains filtered or unexported fields
}
func (*RoomsDeclineCall) Do ¶
func (c *RoomsDeclineCall) Do() (*Room, error)
type RoomsDismissCall ¶
type RoomsDismissCall struct {
// contains filtered or unexported fields
}
func (*RoomsDismissCall) Do ¶
func (c *RoomsDismissCall) Do() error
type RoomsGetCall ¶
type RoomsGetCall struct {
// contains filtered or unexported fields
}
func (*RoomsGetCall) Do ¶
func (c *RoomsGetCall) Do() (*Room, error)
func (*RoomsGetCall) Language ¶
func (c *RoomsGetCall) Language(language string) *RoomsGetCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type RoomsJoinCall ¶
type RoomsJoinCall struct {
// contains filtered or unexported fields
}
func (*RoomsJoinCall) Do ¶
func (c *RoomsJoinCall) Do() (*Room, error)
type RoomsLeaveCall ¶
type RoomsLeaveCall struct {
// contains filtered or unexported fields
}
func (*RoomsLeaveCall) Do ¶
func (c *RoomsLeaveCall) Do() (*Room, error)
type RoomsListCall ¶
type RoomsListCall struct {
// contains filtered or unexported fields
}
func (*RoomsListCall) Do ¶
func (c *RoomsListCall) Do() (*RoomList, error)
func (*RoomsListCall) Language ¶
func (c *RoomsListCall) Language(language string) *RoomsListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*RoomsListCall) MaxResults ¶
func (c *RoomsListCall) MaxResults(maxResults int64) *RoomsListCall
MaxResults sets the optional parameter "maxResults": 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.
func (*RoomsListCall) PageToken ¶
func (c *RoomsListCall) PageToken(pageToken string) *RoomsListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type RoomsReportStatusCall ¶
type RoomsReportStatusCall struct {
// contains filtered or unexported fields
}
func (*RoomsReportStatusCall) Do ¶
func (c *RoomsReportStatusCall) Do() (*RoomStatus, error)
type RoomsService ¶
type RoomsService struct {
// contains filtered or unexported fields
}
func NewRoomsService ¶
func NewRoomsService(s *Service) *RoomsService
func (*RoomsService) Create ¶
func (r *RoomsService) Create(roomcreaterequest *RoomCreateRequest) *RoomsCreateCall
Create: Create a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
func (*RoomsService) Decline ¶
func (r *RoomsService) Decline(roomId string) *RoomsDeclineCall
Decline: Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
func (*RoomsService) Dismiss ¶
func (r *RoomsService) Dismiss(roomId string) *RoomsDismissCall
Dismiss: Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
func (*RoomsService) Get ¶
func (r *RoomsService) Get(roomId string) *RoomsGetCall
Get: Get the data for a room.
func (*RoomsService) Join ¶
func (r *RoomsService) Join(roomId string, roomjoinrequest *RoomJoinRequest) *RoomsJoinCall
Join: Join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
func (*RoomsService) Leave ¶
func (r *RoomsService) Leave(roomId string, roomleaverequest *RoomLeaveRequest) *RoomsLeaveCall
Leave: Leave a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
func (*RoomsService) List ¶
func (r *RoomsService) List() *RoomsListCall
List: Returns invitations to join rooms.
func (*RoomsService) ReportStatus ¶
func (r *RoomsService) ReportStatus(roomId string, roomp2pstatuses *RoomP2PStatuses) *RoomsReportStatusCall
ReportStatus: 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.
type ScoreSubmission ¶
type ScoreSubmission struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#scoreSubmission. Kind string `json:"kind,omitempty"` // LeaderboardId: The leaderboard this score is being submitted to. LeaderboardId string `json:"leaderboardId,omitempty"` // Score: The new score being submitted. Score int64 `json:"score,omitempty,string"` // ScoreTag: Additional information about this score. Values will // contain no more than 64 URI-safe characters as defined by section 2.3 // of RFC 3986. ScoreTag string `json:"scoreTag,omitempty"` }
type ScoresGetCall ¶
type ScoresGetCall struct {
// contains filtered or unexported fields
}
func (*ScoresGetCall) Do ¶
func (c *ScoresGetCall) Do() (*PlayerLeaderboardScoreListResponse, error)
func (*ScoresGetCall) IncludeRankType ¶
func (c *ScoresGetCall) IncludeRankType(includeRankType string) *ScoresGetCall
IncludeRankType sets the optional parameter "includeRankType": The types of ranks to return. If the parameter is omitted, no ranks will be returned.
func (*ScoresGetCall) Language ¶
func (c *ScoresGetCall) Language(language string) *ScoresGetCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*ScoresGetCall) MaxResults ¶
func (c *ScoresGetCall) MaxResults(maxResults int64) *ScoresGetCall
MaxResults sets the optional parameter "maxResults": The maximum number of leaderboard scores to return in the response. For any response, the actual number of leaderboard scores returned may be less than the specified maxResults.
func (*ScoresGetCall) PageToken ¶
func (c *ScoresGetCall) PageToken(pageToken string) *ScoresGetCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type ScoresListCall ¶
type ScoresListCall struct {
// contains filtered or unexported fields
}
func (*ScoresListCall) Do ¶
func (c *ScoresListCall) Do() (*LeaderboardScores, error)
func (*ScoresListCall) Language ¶
func (c *ScoresListCall) Language(language string) *ScoresListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*ScoresListCall) MaxResults ¶
func (c *ScoresListCall) MaxResults(maxResults int64) *ScoresListCall
MaxResults sets the optional parameter "maxResults": The maximum number of leaderboard scores to return in the response. For any response, the actual number of leaderboard scores returned may be less than the specified maxResults.
func (*ScoresListCall) PageToken ¶
func (c *ScoresListCall) PageToken(pageToken string) *ScoresListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type ScoresListWindowCall ¶
type ScoresListWindowCall struct {
// contains filtered or unexported fields
}
func (*ScoresListWindowCall) Do ¶
func (c *ScoresListWindowCall) Do() (*LeaderboardScores, error)
func (*ScoresListWindowCall) Language ¶
func (c *ScoresListWindowCall) Language(language string) *ScoresListWindowCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*ScoresListWindowCall) MaxResults ¶
func (c *ScoresListWindowCall) MaxResults(maxResults int64) *ScoresListWindowCall
MaxResults sets the optional parameter "maxResults": The maximum number of leaderboard scores to return in the response. For any response, the actual number of leaderboard scores returned may be less than the specified maxResults.
func (*ScoresListWindowCall) PageToken ¶
func (c *ScoresListWindowCall) PageToken(pageToken string) *ScoresListWindowCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
func (*ScoresListWindowCall) ResultsAbove ¶
func (c *ScoresListWindowCall) ResultsAbove(resultsAbove int64) *ScoresListWindowCall
ResultsAbove sets the optional parameter "resultsAbove": The preferred number of scores to return above the player's score. More scores may be returned if the player is at the bottom of the leaderboard; fewer may be returned if the player is at the top. Must be less than or equal to maxResults.
func (*ScoresListWindowCall) ReturnTopIfAbsent ¶
func (c *ScoresListWindowCall) ReturnTopIfAbsent(returnTopIfAbsent bool) *ScoresListWindowCall
ReturnTopIfAbsent sets the optional parameter "returnTopIfAbsent": True if the top scores should be returned when the player is not in the leaderboard. Defaults to true.
type ScoresService ¶
type ScoresService struct {
// contains filtered or unexported fields
}
func NewScoresService ¶
func NewScoresService(s *Service) *ScoresService
func (*ScoresService) Get ¶
func (r *ScoresService) Get(playerId string, leaderboardId string, timeSpan string) *ScoresGetCall
Get: Get high scores, and optionally ranks, in leaderboards for the currently authenticated player. For a specific time span, leaderboardId can be set to ALL to retrieve data for all leaderboards in a given time span. NOTE: You cannot ask for 'ALL' leaderboards and 'ALL' timeSpans in the same request; only one parameter may be set to 'ALL'.
func (*ScoresService) List ¶
func (r *ScoresService) List(leaderboardId string, collection string, timeSpan string) *ScoresListCall
List: Lists the scores in a leaderboard, starting from the top.
func (*ScoresService) ListWindow ¶
func (r *ScoresService) ListWindow(leaderboardId string, collection string, timeSpan string) *ScoresListWindowCall
ListWindow: Lists the scores in a leaderboard around (and including) a player's score.
func (*ScoresService) Submit ¶
func (r *ScoresService) Submit(leaderboardId string, score int64) *ScoresSubmitCall
Submit: Submits a score to the specified leaderboard.
func (*ScoresService) SubmitMultiple ¶
func (r *ScoresService) SubmitMultiple(playerscoresubmissionlist *PlayerScoreSubmissionList) *ScoresSubmitMultipleCall
SubmitMultiple: Submits multiple scores to leaderboards.
type ScoresSubmitCall ¶
type ScoresSubmitCall struct {
// contains filtered or unexported fields
}
func (*ScoresSubmitCall) Do ¶
func (c *ScoresSubmitCall) Do() (*PlayerScoreResponse, error)
func (*ScoresSubmitCall) Language ¶
func (c *ScoresSubmitCall) Language(language string) *ScoresSubmitCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*ScoresSubmitCall) ScoreTag ¶
func (c *ScoresSubmitCall) ScoreTag(scoreTag string) *ScoresSubmitCall
ScoreTag sets the optional parameter "scoreTag": Additional information about the score you're submitting. Values must contain no more than 64 URI-safe characters as defined by section 2.3 of RFC 3986.
type ScoresSubmitMultipleCall ¶
type ScoresSubmitMultipleCall struct {
// contains filtered or unexported fields
}
func (*ScoresSubmitMultipleCall) Do ¶
func (c *ScoresSubmitMultipleCall) Do() (*PlayerScoreListResponse, error)
func (*ScoresSubmitMultipleCall) Language ¶
func (c *ScoresSubmitMultipleCall) Language(language string) *ScoresSubmitMultipleCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type Service ¶
type Service struct { BasePath string // API endpoint base URL AchievementDefinitions *AchievementDefinitionsService Achievements *AchievementsService Applications *ApplicationsService Leaderboards *LeaderboardsService Players *PlayersService Pushtokens *PushtokensService Revisions *RevisionsService Rooms *RoomsService Scores *ScoresService TurnBasedMatches *TurnBasedMatchesService // contains filtered or unexported fields }
type TurnBasedAutoMatchingCriteria ¶
type TurnBasedAutoMatchingCriteria struct { // ExclusiveBitmask: 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. ExclusiveBitmask int64 `json:"exclusiveBitmask,omitempty,string"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedAutoMatchingCriteria. Kind string `json:"kind,omitempty"` // MaxAutoMatchingPlayers: The maximum number of players that should be // added to the match by auto-matching. MaxAutoMatchingPlayers int64 `json:"maxAutoMatchingPlayers,omitempty"` // MinAutoMatchingPlayers: The minimum number of players that should be // added to the match by auto-matching. MinAutoMatchingPlayers int64 `json:"minAutoMatchingPlayers,omitempty"` }
type TurnBasedMatch ¶
type TurnBasedMatch struct { // ApplicationId: The ID of the application being played. ApplicationId string `json:"applicationId,omitempty"` // AutoMatchingCriteria: Criteria for auto-matching players into this // match. AutoMatchingCriteria *TurnBasedAutoMatchingCriteria `json:"autoMatchingCriteria,omitempty"` // CreationDetails: Details about the match creation. CreationDetails *TurnBasedMatchModification `json:"creationDetails,omitempty"` // Data: The data / game state for this match. Data *TurnBasedMatchData `json:"data,omitempty"` // Description: This short description is generated by our servers based // on turn state and is localized and worded relative to the player // requesting the match. It is intended to be displayed when the match // is shown in a list. Description string `json:"description,omitempty"` // InviterId: The ID of the participant that invited the user to the // match. Not set if the user was not invited to the match. InviterId string `json:"inviterId,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatch. Kind string `json:"kind,omitempty"` // LastUpdateDetails: Details about the last update to the match. LastUpdateDetails *TurnBasedMatchModification `json:"lastUpdateDetails,omitempty"` // MatchId: Globally unique ID for a turn-based match. MatchId string `json:"matchId,omitempty"` // MatchNumber: The number of the match in a chain of rematches. Will be // set to 1 for the first match and incremented by 1 for each rematch. MatchNumber int64 `json:"matchNumber,omitempty"` // MatchVersion: The version of this match: an increasing counter, used // to avoid out-of-date updates to the match. MatchVersion int64 `json:"matchVersion,omitempty"` // Participants: The participants involved in the match, along with // their statuses. Includes participants who have left or declined // invitations. Participants []*TurnBasedMatchParticipant `json:"participants,omitempty"` // PendingParticipantId: The ID of the participant that is taking a // turn. PendingParticipantId string `json:"pendingParticipantId,omitempty"` // PreviousMatchData: The data / game state for the previous match; set // for the first turn of rematches only. PreviousMatchData *TurnBasedMatchData `json:"previousMatchData,omitempty"` // RematchId: The ID of a rematch of this match. Only set for completed // matches that have been rematched. RematchId string `json:"rematchId,omitempty"` // Results: The results reported for this match. Results []*ParticipantResult `json:"results,omitempty"` // Status: The status of the match. // Possible values are: // - // "MATCH_AUTO_MATCHING" - One or more slots need to be filled by // auto-matching; the match cannot be established until they are filled. // // - "MATCH_ACTIVE" - The match has started. // - "MATCH_COMPLETE" - The // match has finished. // - "MATCH_CANCELED" - The match was canceled. // - // "MATCH_EXPIRED" - The match expired due to inactivity. // - // "MATCH_DELETED" - The match should no longer be shown on the client. // Returned only for tombstones for matches when sync is called. Status string `json:"status,omitempty"` // UserMatchStatus: The status of the current user in the match. Derived // from the match type, match status, the user's participant status, and // the pending participant for the match. // Possible values are: // - // "USER_INVITED" - The user has been invited to join the match and has // not responded yet. // - "USER_AWAITING_TURN" - The user is waiting for // their turn. // - "USER_TURN" - The user has an action to take in the // match. // - "USER_MATCH_COMPLETED" - The match has ended (it is // completed, canceled, or expired.) UserMatchStatus string `json:"userMatchStatus,omitempty"` // Variant: The variant / mode of the application being played; can be // any integer value, or left blank. Variant int64 `json:"variant,omitempty"` // WithParticipantId: The ID of another participant in the match that // can be used when describing the participants the user is playing // with. WithParticipantId string `json:"withParticipantId,omitempty"` }
type TurnBasedMatchCreateRequest ¶
type TurnBasedMatchCreateRequest struct { // AutoMatchingCriteria: Criteria for auto-matching players into this // match. AutoMatchingCriteria *TurnBasedAutoMatchingCriteria `json:"autoMatchingCriteria,omitempty"` // InvitedPlayerIds: The player ids to invite to the match. InvitedPlayerIds []string `json:"invitedPlayerIds,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchCreateRequest. Kind string `json:"kind,omitempty"` // RequestId: A randomly generated numeric ID. This number is used at // the server to ensure that the request is handled correctly across // retries. RequestId int64 `json:"requestId,omitempty,string"` // Variant: 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. Variant int64 `json:"variant,omitempty"` }
type TurnBasedMatchData ¶
type TurnBasedMatchData struct { // Data: The byte representation of the data (limited to 128 kB), as a // Base64-encoded string with the URL_SAFE encoding option. Data string `json:"data,omitempty"` // DataAvailable: True if this match has data available but it wasn't // returned in a list response; fetching the match individually will // retrieve this data. DataAvailable bool `json:"dataAvailable,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchData. Kind string `json:"kind,omitempty"` }
type TurnBasedMatchDataRequest ¶
type TurnBasedMatchDataRequest struct { // Data: The byte representation of the data (limited to 128 kB), as a // Base64-encoded string with the URL_SAFE encoding option. Data string `json:"data,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchDataRequest. Kind string `json:"kind,omitempty"` }
type TurnBasedMatchList ¶
type TurnBasedMatchList struct { // Items: The matches. Items []*TurnBasedMatch `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchList. Kind string `json:"kind,omitempty"` // NextPageToken: The pagination token for the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type TurnBasedMatchModification ¶
type TurnBasedMatchModification struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchModification. Kind string `json:"kind,omitempty"` // ModifiedTimestampMillis: The timestamp at which they modified the // match, in milliseconds since the epoch in UTC. ModifiedTimestampMillis int64 `json:"modifiedTimestampMillis,omitempty,string"` // ParticipantId: The ID of the participant that modified the match. ParticipantId string `json:"participantId,omitempty"` }
type TurnBasedMatchParticipant ¶
type TurnBasedMatchParticipant struct { // AutoMatched: True if this participant was auto-matched with the // requesting player. AutoMatched bool `json:"autoMatched,omitempty"` // AutoMatchedPlayer: Information about a player that has been // anonymously auto-matched against the requesting player. (Either // player or autoMatchedPlayer will be set.) AutoMatchedPlayer *AnonymousPlayer `json:"autoMatchedPlayer,omitempty"` // Id: An identifier for the participant in the scope of the match. // Cannot be used to identify a player across matches or in other // contexts. Id string `json:"id,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchParticipant. Kind string `json:"kind,omitempty"` // Player: Information about the player. Not populated if this player // was anonymously auto-matched against the requesting player. (Either // player or autoMatchedPlayer will be set.) Player *Player `json:"player,omitempty"` // Status: The status of the participant with respect to the // match. // Possible values are: // - "PARTICIPANT_NOT_INVITED_YET" - The // participant is slated to be invited to the match, but the invitation // has not been sent; the invite will be sent when it becomes their // turn. // - "PARTICIPANT_INVITED" - The participant has been invited to // join the match, but has not yet responded. // - "PARTICIPANT_JOINED" - // The participant has joined the match (either after creating it or // accepting an invitation.) // - "PARTICIPANT_DECLINED" - The participant // declined an invitation to join the match. // - "PARTICIPANT_LEFT" - The // participant joined the match and then left it. // - // "PARTICIPANT_FINISHED" - The participant finished playing in the // match. // - "PARTICIPANT_UNRESPONSIVE" - The participant did not take // their turn in the allotted time. Status string `json:"status,omitempty"` }
type TurnBasedMatchRematch ¶
type TurnBasedMatchRematch struct { // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchRematch. Kind string `json:"kind,omitempty"` // PreviousMatch: The old match that the rematch was created from; will // be updated such that the rematchId field will point at the new match. PreviousMatch *TurnBasedMatch `json:"previousMatch,omitempty"` // Rematch: The newly created match; a rematch of the old match with the // same participants. Rematch *TurnBasedMatch `json:"rematch,omitempty"` }
type TurnBasedMatchResults ¶
type TurnBasedMatchResults struct { // Data: The final match data. Data *TurnBasedMatchDataRequest `json:"data,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchResults. Kind string `json:"kind,omitempty"` // MatchVersion: The version of the match being updated. MatchVersion int64 `json:"matchVersion,omitempty"` // Results: The match results for the participants in the match. Results []*ParticipantResult `json:"results,omitempty"` }
type TurnBasedMatchSync ¶
type TurnBasedMatchSync struct { // Items: The matches. Items []*TurnBasedMatch `json:"items,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchSync. Kind string `json:"kind,omitempty"` // MoreAvailable: True if there were more matches available to fetch at // the time the response was generated (which were not returned due to // page size limits.) MoreAvailable bool `json:"moreAvailable,omitempty"` // NextPageToken: The pagination token for the next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type TurnBasedMatchTurn ¶
type TurnBasedMatchTurn struct { // Data: The shared game state data after the turn is over. Data *TurnBasedMatchDataRequest `json:"data,omitempty"` // Kind: Uniquely identifies the type of this resource. Value is always // the fixed string games#turnBasedMatchTurn. Kind string `json:"kind,omitempty"` // MatchVersion: The version of this match: an increasing counter, used // to avoid out-of-date updates to the match. MatchVersion int64 `json:"matchVersion,omitempty"` // PendingParticipantId: The ID of the participant who should take their // turn next. May be set to the current player's participant ID to // update match state without changing the turn. If not set, the match // will wait for other player(s) to join via automatching; this is only // valid if automatch criteria is set on the match with remaining slots // for automatched players. PendingParticipantId string `json:"pendingParticipantId,omitempty"` // Results: The match results for the participants in the match. Results []*ParticipantResult `json:"results,omitempty"` }
type TurnBasedMatchesCancelCall ¶
type TurnBasedMatchesCancelCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesCancelCall) Do ¶
func (c *TurnBasedMatchesCancelCall) Do() error
type TurnBasedMatchesCreateCall ¶
type TurnBasedMatchesCreateCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesCreateCall) Do ¶
func (c *TurnBasedMatchesCreateCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesCreateCall) Language ¶
func (c *TurnBasedMatchesCreateCall) Language(language string) *TurnBasedMatchesCreateCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesDeclineCall ¶
type TurnBasedMatchesDeclineCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesDeclineCall) Do ¶
func (c *TurnBasedMatchesDeclineCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesDeclineCall) Language ¶
func (c *TurnBasedMatchesDeclineCall) Language(language string) *TurnBasedMatchesDeclineCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesDismissCall ¶
type TurnBasedMatchesDismissCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesDismissCall) Do ¶
func (c *TurnBasedMatchesDismissCall) Do() error
type TurnBasedMatchesFinishCall ¶
type TurnBasedMatchesFinishCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesFinishCall) Do ¶
func (c *TurnBasedMatchesFinishCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesFinishCall) Language ¶
func (c *TurnBasedMatchesFinishCall) Language(language string) *TurnBasedMatchesFinishCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesGetCall ¶
type TurnBasedMatchesGetCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesGetCall) Do ¶
func (c *TurnBasedMatchesGetCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesGetCall) IncludeMatchData ¶
func (c *TurnBasedMatchesGetCall) IncludeMatchData(includeMatchData bool) *TurnBasedMatchesGetCall
IncludeMatchData sets the optional parameter "includeMatchData": Get match data along with metadata.
func (*TurnBasedMatchesGetCall) Language ¶
func (c *TurnBasedMatchesGetCall) Language(language string) *TurnBasedMatchesGetCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesJoinCall ¶
type TurnBasedMatchesJoinCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesJoinCall) Do ¶
func (c *TurnBasedMatchesJoinCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesJoinCall) Language ¶
func (c *TurnBasedMatchesJoinCall) Language(language string) *TurnBasedMatchesJoinCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesLeaveCall ¶
type TurnBasedMatchesLeaveCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesLeaveCall) Do ¶
func (c *TurnBasedMatchesLeaveCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesLeaveCall) Language ¶
func (c *TurnBasedMatchesLeaveCall) Language(language string) *TurnBasedMatchesLeaveCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
type TurnBasedMatchesLeaveTurnCall ¶
type TurnBasedMatchesLeaveTurnCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesLeaveTurnCall) Do ¶
func (c *TurnBasedMatchesLeaveTurnCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesLeaveTurnCall) Language ¶
func (c *TurnBasedMatchesLeaveTurnCall) Language(language string) *TurnBasedMatchesLeaveTurnCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*TurnBasedMatchesLeaveTurnCall) PendingParticipantId ¶
func (c *TurnBasedMatchesLeaveTurnCall) PendingParticipantId(pendingParticipantId string) *TurnBasedMatchesLeaveTurnCall
PendingParticipantId sets the optional parameter "pendingParticipantId": The ID of another participant who should take their turn next. If not set, the match will wait for other player(s) to join via automatching; this is only valid if automatch criteria is set on the match with remaining slots for automatched players.
type TurnBasedMatchesListCall ¶
type TurnBasedMatchesListCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesListCall) Do ¶
func (c *TurnBasedMatchesListCall) Do() (*TurnBasedMatchList, error)
func (*TurnBasedMatchesListCall) IncludeMatchData ¶
func (c *TurnBasedMatchesListCall) IncludeMatchData(includeMatchData bool) *TurnBasedMatchesListCall
IncludeMatchData sets the optional parameter "includeMatchData": True if match data should be returned in the response. Note that not all data will necessarily be returned if include_match_data is true; the server may decide to only return data for some of the matches to limit download size for the client. The remainder of the data for these matches will be retrievable on request.
func (*TurnBasedMatchesListCall) Language ¶
func (c *TurnBasedMatchesListCall) Language(language string) *TurnBasedMatchesListCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*TurnBasedMatchesListCall) MaxCompletedMatches ¶
func (c *TurnBasedMatchesListCall) MaxCompletedMatches(maxCompletedMatches int64) *TurnBasedMatchesListCall
MaxCompletedMatches sets the optional parameter "maxCompletedMatches": The maximum number of completed or canceled matches to return in the response. If not set, all matches returned could be completed or canceled.
func (*TurnBasedMatchesListCall) MaxResults ¶
func (c *TurnBasedMatchesListCall) MaxResults(maxResults int64) *TurnBasedMatchesListCall
MaxResults sets the optional parameter "maxResults": The maximum number of matches to return in the response, used for paging. For any response, the actual number of matches to return may be less than the specified maxResults.
func (*TurnBasedMatchesListCall) PageToken ¶
func (c *TurnBasedMatchesListCall) PageToken(pageToken string) *TurnBasedMatchesListCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type TurnBasedMatchesRematchCall ¶
type TurnBasedMatchesRematchCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesRematchCall) Do ¶
func (c *TurnBasedMatchesRematchCall) Do() (*TurnBasedMatchRematch, error)
func (*TurnBasedMatchesRematchCall) Language ¶
func (c *TurnBasedMatchesRematchCall) Language(language string) *TurnBasedMatchesRematchCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*TurnBasedMatchesRematchCall) RequestId ¶
func (c *TurnBasedMatchesRematchCall) RequestId(requestId int64) *TurnBasedMatchesRematchCall
RequestId sets the optional parameter "requestId": A randomly generated numeric ID for each request specified by the caller. This number is used at the server to ensure that the request is handled correctly across retries.
type TurnBasedMatchesService ¶
type TurnBasedMatchesService struct {
// contains filtered or unexported fields
}
func NewTurnBasedMatchesService ¶
func NewTurnBasedMatchesService(s *Service) *TurnBasedMatchesService
func (*TurnBasedMatchesService) Cancel ¶
func (r *TurnBasedMatchesService) Cancel(matchId string) *TurnBasedMatchesCancelCall
Cancel: Cancel a turn-based match.
func (*TurnBasedMatchesService) Create ¶
func (r *TurnBasedMatchesService) Create(turnbasedmatchcreaterequest *TurnBasedMatchCreateRequest) *TurnBasedMatchesCreateCall
Create: Create a turn-based match.
func (*TurnBasedMatchesService) Decline ¶
func (r *TurnBasedMatchesService) Decline(matchId string) *TurnBasedMatchesDeclineCall
Decline: Decline an invitation to play a turn-based match.
func (*TurnBasedMatchesService) Dismiss ¶
func (r *TurnBasedMatchesService) Dismiss(matchId string) *TurnBasedMatchesDismissCall
Dismiss: Dismiss a turn-based match from the match list. The match will no longer show up in the list and will not generate notifications.
func (*TurnBasedMatchesService) Finish ¶
func (r *TurnBasedMatchesService) Finish(matchId string, turnbasedmatchresults *TurnBasedMatchResults) *TurnBasedMatchesFinishCall
Finish: Finish a turn-based match. Each player should make this call once, after all results are in. Only the player whose turn it is may make the first call to Finish, and can pass in the final match state.
func (*TurnBasedMatchesService) Get ¶
func (r *TurnBasedMatchesService) Get(matchId string) *TurnBasedMatchesGetCall
Get: Get the data for a turn-based match.
func (*TurnBasedMatchesService) Join ¶
func (r *TurnBasedMatchesService) Join(matchId string) *TurnBasedMatchesJoinCall
Join: Join a turn-based match.
func (*TurnBasedMatchesService) Leave ¶
func (r *TurnBasedMatchesService) Leave(matchId string) *TurnBasedMatchesLeaveCall
Leave: Leave a turn-based match when it is not the current player's turn, without canceling the match.
func (*TurnBasedMatchesService) LeaveTurn ¶
func (r *TurnBasedMatchesService) LeaveTurn(matchId string, matchVersion int64) *TurnBasedMatchesLeaveTurnCall
LeaveTurn: Leave a turn-based match during the current player's turn, without canceling the match.
func (*TurnBasedMatchesService) List ¶
func (r *TurnBasedMatchesService) List() *TurnBasedMatchesListCall
List: Returns turn-based matches the player is or was involved in.
func (*TurnBasedMatchesService) Rematch ¶
func (r *TurnBasedMatchesService) Rematch(matchId string) *TurnBasedMatchesRematchCall
Rematch: Create a rematch of a match that was previously completed, with the same participants. This can be called by only one player on a match still in their list; the player must have called Finish first. Returns the newly created match; it will be the caller's turn.
func (*TurnBasedMatchesService) Sync ¶
func (r *TurnBasedMatchesService) Sync() *TurnBasedMatchesSyncCall
Sync: Returns turn-based matches the player is or was involved in that changed since the last sync call, with the least recent changes coming first. Matches that should be removed from the local cache will have a status of MATCH_DELETED.
func (*TurnBasedMatchesService) TakeTurn ¶
func (r *TurnBasedMatchesService) TakeTurn(matchId string, turnbasedmatchturn *TurnBasedMatchTurn) *TurnBasedMatchesTakeTurnCall
TakeTurn: Commit the results of a player turn.
type TurnBasedMatchesSyncCall ¶
type TurnBasedMatchesSyncCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesSyncCall) Do ¶
func (c *TurnBasedMatchesSyncCall) Do() (*TurnBasedMatchSync, error)
func (*TurnBasedMatchesSyncCall) IncludeMatchData ¶
func (c *TurnBasedMatchesSyncCall) IncludeMatchData(includeMatchData bool) *TurnBasedMatchesSyncCall
IncludeMatchData sets the optional parameter "includeMatchData": True if match data should be returned in the response. Note that not all data will necessarily be returned if include_match_data is true; the server may decide to only return data for some of the matches to limit download size for the client. The remainder of the data for these matches will be retrievable on request.
func (*TurnBasedMatchesSyncCall) Language ¶
func (c *TurnBasedMatchesSyncCall) Language(language string) *TurnBasedMatchesSyncCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.
func (*TurnBasedMatchesSyncCall) MaxCompletedMatches ¶
func (c *TurnBasedMatchesSyncCall) MaxCompletedMatches(maxCompletedMatches int64) *TurnBasedMatchesSyncCall
MaxCompletedMatches sets the optional parameter "maxCompletedMatches": The maximum number of completed or canceled matches to return in the response. If not set, all matches returned could be completed or canceled.
func (*TurnBasedMatchesSyncCall) MaxResults ¶
func (c *TurnBasedMatchesSyncCall) MaxResults(maxResults int64) *TurnBasedMatchesSyncCall
MaxResults sets the optional parameter "maxResults": The maximum number of matches to return in the response, used for paging. For any response, the actual number of matches to return may be less than the specified maxResults.
func (*TurnBasedMatchesSyncCall) PageToken ¶
func (c *TurnBasedMatchesSyncCall) PageToken(pageToken string) *TurnBasedMatchesSyncCall
PageToken sets the optional parameter "pageToken": The token returned by the previous request.
type TurnBasedMatchesTakeTurnCall ¶
type TurnBasedMatchesTakeTurnCall struct {
// contains filtered or unexported fields
}
func (*TurnBasedMatchesTakeTurnCall) Do ¶
func (c *TurnBasedMatchesTakeTurnCall) Do() (*TurnBasedMatch, error)
func (*TurnBasedMatchesTakeTurnCall) Language ¶
func (c *TurnBasedMatchesTakeTurnCall) Language(language string) *TurnBasedMatchesTakeTurnCall
Language sets the optional parameter "language": The preferred language to use for strings returned by this method.