REST Resource: scores
Оптимизируйте свои подборки
Сохраняйте и классифицируйте контент в соответствии со своими настройками.
Ресурс: GetLeaderboardScoresResponse
Список результатов игроков в таблице лидеров.
JSON-представление |
---|
{
"kind": string,
"nextPageToken": string,
"player": {
object (Player )
},
"items": [
{
object (LeaderboardScore )
}
]
} |
Поля |
---|
kind | string Уникально определяет тип этого ресурса. Значением всегда является фиксированная строка games#playerLeaderboardScoreListResponse . |
nextPageToken | string Токен нумерации страниц для следующей страницы результатов. |
player | object ( Player ) Ресурсы игрока для владельца этого счета. |
items[] | object ( LeaderboardScore ) Рейтинг лидеров. |
Таблица лидеровОценка
Объект таблицы лидеров игроков.
Поля |
---|
kind | string Уникально определяет тип этого ресурса. Значением всегда является фиксированная строка games#playerLeaderboardScore . |
leaderboard_id | string Идентификатор таблицы лидеров, в которой находится этот результат. |
scoreValue | string ( int64 format) Числовое значение этого балла. |
scoreString | string Форматированное значение этой оценки. |
publicRank | object ( LeaderboardScoreRank ) Публичный рейтинг очков в этой таблице лидеров. Этот объект не будет присутствовать, если пользователь не публикует свои результаты публично. |
socialRank | object ( LeaderboardScoreRank ) Социальный рейтинг в этой таблице лидеров. |
friendsRank | object ( LeaderboardScoreRank ) Рейтинг очков в коллекции друзей для этой таблицы лидеров. |
timeSpan | enum ( ScoreTimeSpan ) Временной интервал этой оценки. |
writeTimestamp | string ( int64 format) Временная метка, в которой был записан этот результат, в миллисекундах с начала эпохи в формате UTC. |
scoreTag | string Дополнительная информация о счете. Значения должны содержать не более 64 символов, безопасных для URI, как определено в разделе 2.3 RFC 3986. |
Таблица лидеровОценкаРанг
Рейтинг в таблице лидеров.
JSON-представление |
---|
{
"kind": string,
"rank": string,
"formattedRank": string,
"numScores": string,
"formattedNumScores": string
} |
Поля |
---|
kind | string Уникально определяет тип этого ресурса. Значением всегда является фиксированная строка games#leaderboardScoreRank . |
rank | string ( int64 format) Место в таблице лидеров. |
formattedRank | string Ранг в таблице лидеров в виде строки. |
numScores | string ( int64 format) Количество очков в таблице лидеров. |
formattedNumScores | string Количество очков в таблице лидеров в виде строки. |
ОценкаTimeSpan
Определяет возможные временные интервалы для оценки.
Перечисления |
---|
ALL_TIME | Этот результат является рекордным за все время. |
WEEKLY | Оценка представляет собой еженедельную оценку. |
DAILY | Оценка представляет собой ежедневную оценку. |
Методы |
---|
| Получайте высокие баллы и, при желании, места в таблицах лидеров для игрока, прошедшего проверку подлинности. |
| Перечисляет результаты в таблице лидеров, начиная сверху. |
| Перечисляет результаты в таблице лидеров вокруг (и включая) очков игрока. |
| Отправляет результат в указанную таблицу лидеров. |
| Отправляет несколько результатов в списки лидеров. |
Контент и образцы кода на этой странице предоставлены по лицензиям. Java и OpenJDK – это зарегистрированные товарные знаки корпорации Oracle и ее аффилированных лиц.
Последнее обновление: 2025-07-29 UTC.
[[["Прост для понимания","easyToUnderstand","thumb-up"],["Помог мне решить мою проблему","solvedMyProblem","thumb-up"],["Другое","otherUp","thumb-up"]],[["Отсутствует нужная мне информация","missingTheInformationINeed","thumb-down"],["Слишком сложен/слишком много шагов","tooComplicatedTooManySteps","thumb-down"],["Устарел","outOfDate","thumb-down"],["Проблема с переводом текста","translationIssue","thumb-down"],["Проблемы образцов/кода","samplesCodeIssue","thumb-down"],["Другое","otherDown","thumb-down"]],["Последнее обновление: 2025-07-29 UTC."],[],[],null,["# REST Resource: scores\n\n- [Resource: GetLeaderboardScoresResponse](#GetLeaderboardScoresResponse)\n - [JSON representation](#GetLeaderboardScoresResponse.SCHEMA_REPRESENTATION)\n- [LeaderboardScore](#LeaderboardScore)\n - [JSON representation](#LeaderboardScore.SCHEMA_REPRESENTATION)\n- [LeaderboardScoreRank](#LeaderboardScoreRank)\n - [JSON representation](#LeaderboardScoreRank.SCHEMA_REPRESENTATION)\n- [ScoreTimeSpan](#ScoreTimeSpan)\n- [Methods](#METHODS_SUMMARY)\n\nResource: GetLeaderboardScoresResponse\n--------------------------------------\n\nA list of player leaderboard scores.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"kind\": string, \"nextPageToken\": string, \"player\": { object (/games/services/web/api/rest/v1/players#Player) }, \"items\": [ { object (/games/services/web/api/rest/v1/scores#LeaderboardScore) } ] } ``` |\n\n| Fields ||\n|-----------------|--------------------------------------------------------------------------------------------------------------------------------------|\n| `kind` | `string` Uniquely identifies the type of this resource. Value is always the fixed string `games#playerLeaderboardScoreListResponse`. |\n| `nextPageToken` | `string` The pagination token for the next page of results. |\n| `player` | `object (`[Player](/games/services/web/api/rest/v1/players#Player)`)` The Player resources for the owner of this score. |\n| `items[]` | `object (`[LeaderboardScore](/games/services/web/api/rest/v1/scores#LeaderboardScore)`)` The leaderboard scores. |\n\nLeaderboardScore\n----------------\n\nA player leaderboard score object.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"kind\": string, \"leaderboard_id\": string, \"scoreValue\": string, \"scoreString\": string, \"publicRank\": { object (/games/services/web/api/rest/v1/scores#LeaderboardScoreRank) }, \"socialRank\": { object (/games/services/web/api/rest/v1/scores#LeaderboardScoreRank) }, \"friendsRank\": { object (/games/services/web/api/rest/v1/scores#LeaderboardScoreRank) }, \"timeSpan\": enum (/games/services/web/api/rest/v1/scores#ScoreTimeSpan), \"writeTimestamp\": string, \"scoreTag\": string } ``` |\n\n| Fields ||\n|------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `kind` | `string` Uniquely identifies the type of this resource. Value is always the fixed string `games#playerLeaderboardScore`. |\n| `leaderboard_id` | `string` The ID of the leaderboard this score is in. |\n| `scoreValue` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The numerical value of this score. |\n| `scoreString` | `string` The formatted value of this score. |\n| `publicRank` | `object (`[LeaderboardScoreRank](/games/services/web/api/rest/v1/scores#LeaderboardScoreRank)`)` The public rank of the score in this leaderboard. This object will not be present if the user is not sharing their scores publicly. |\n| `socialRank` | `object (`[LeaderboardScoreRank](/games/services/web/api/rest/v1/scores#LeaderboardScoreRank)`)` The social rank of the score in this leaderboard. |\n| `friendsRank` | `object (`[LeaderboardScoreRank](/games/services/web/api/rest/v1/scores#LeaderboardScoreRank)`)` The rank of the score in the friends collection for this leaderboard. |\n| `timeSpan` | `enum (`[ScoreTimeSpan](/games/services/web/api/rest/v1/scores#ScoreTimeSpan)`)` The time span of this score. |\n| `writeTimestamp` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The timestamp at which this score was recorded, in milliseconds since the epoch in UTC. |\n| `scoreTag` | `string` Additional information about the score. Values must contain no more than 64 URI-safe characters as defined by section 2.3 of RFC 3986. |\n\nLeaderboardScoreRank\n--------------------\n\nA score rank in a leaderboard.\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"kind\": string, \"rank\": string, \"formattedRank\": string, \"numScores\": string, \"formattedNumScores\": string } ``` |\n\n| Fields ||\n|----------------------|------------------------------------------------------------------------------------------------------------------------------|\n| `kind` | `string` Uniquely identifies the type of this resource. Value is always the fixed string `games#leaderboardScoreRank`. |\n| `rank` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The rank in the leaderboard. |\n| `formattedRank` | `string` The rank in the leaderboard as a string. |\n| `numScores` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The number of scores in the leaderboard. |\n| `formattedNumScores` | `string` The number of scores in the leaderboard as a string. |\n\nScoreTimeSpan\n-------------\n\nDefines possible time spans for a score.\n\n| Enums ||\n|------------|---------------------------------|\n| `ALL_TIME` | The score is an all-time score. |\n| `WEEKLY` | The score is a weekly score. |\n| `DAILY` | The score is a daily score. |\n\n| Methods ------- ||\n|-----------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|\n| ### [get](/games/services/web/api/rest/v1/scores/get) | Get high scores, and optionally ranks, in leaderboards for the currently authenticated player. |\n| ### [list](/games/services/web/api/rest/v1/scores/list) | Lists the scores in a leaderboard, starting from the top. |\n| ### [listWindow](/games/services/web/api/rest/v1/scores/listWindow) | Lists the scores in a leaderboard around (and including) a player's score. |\n| ### [submit](/games/services/web/api/rest/v1/scores/submit) | Submits a score to the specified leaderboard. |\n| ### [submitMultiple](/games/services/web/api/rest/v1/scores/submitMultiple) | Submits multiple scores to leaderboards. |"]]