(new): v1.2 release
Golang lint / lint (push) Successful in 11m32s

This commit is contained in:
2026-08-19 14:58:25 +03:00
parent f03a081ed6
commit 29b208eeec
79 changed files with 7301 additions and 2060 deletions
+19 -8
View File
@@ -3,12 +3,20 @@ package tgapi
// Game represents a game.
// Since: Bot API 2.2
type Game struct {
Title string `json:"title"`
Description string `json:"description"`
Photo []PhotoSize `json:"photo"`
Text string `json:"text,omitempty"`
// Title Title of the game
Title string `json:"title"`
// Description Description of the game
Description string `json:"description"`
// Photo Photo that will be displayed in the game message in chats
Photo []PhotoSize `json:"photo"`
// Text Optional. Brief description of the game or high scores included in the game message. Can be
// automatically edited to include current high scores for the game when the bot calls setGameScore, or
// manually edited using editMessageText. 0-4096 characters.
Text string `json:"text,omitempty"`
// TextEntities Optional. Special entities that appear in text, such as usernames, URLs, bot commands, etc.
TextEntities []MessageEntity `json:"text_entities,omitempty"`
Animation *Animation `json:"animation,omitempty"`
// Animation Optional. Animation that will be displayed in the game message in chats. Upload via BotFather.
Animation *Animation `json:"animation,omitempty"`
}
// CallbackGame is a placeholder for the future use of callback games.
@@ -19,7 +27,10 @@ type CallbackGame struct{}
// Since: Bot API 2.2
// See https://core.telegram.org/bots/api#gamehighscore
type GameHighScore struct {
Position int `json:"position"`
User User `json:"user"`
Score int `json:"score"`
// Position Position in high score table for the game
Position int `json:"position"`
// User User
User User `json:"user"`
// Score Score
Score int `json:"score"`
}