Skip to main content

messages.getGameHighScores

Get highscores of a game

func (c *Client) MessagesGetGameHighScores(ctx context.Context, request *MessagesGetGameHighScoresRequest) (*MessagesHighScores, error)

Calling this method

client.Run(ctx, func(ctx context.Context) error {
api := client.API()

res, err := api.MessagesGetGameHighScores(ctx, &tg.MessagesGetGameHighScoresRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // *MessagesHighScores
return nil
})

Parameters

NameTypeRequiredDescription
PeerInputPeerClassyesWhere was the game sent
IDintyesID of message with game media attachment
UserIDInputUserClassyesGet high scores made by a certain user

Returns

*MessagesHighScores

Possible errors

CodeTypeDescription
400MESSAGE_ID_INVALIDThe provided message id is invalid.
400PEER_ID_INVALIDThe provided peer id is invalid.
400USER_BOT_REQUIREDThis method can only be called by a bot.

References