premium.applyBoost
Apply one or more boosts » to a peer.
func (c *Client) PremiumApplyBoost(ctx context.Context, request *PremiumApplyBoostRequest) (*PremiumMyBoosts, error)
Calling this method
client.Run(ctx, func(ctx context.Context) error {
api := client.API()
res, err := api.PremiumApplyBoost(ctx, &tg.PremiumApplyBoostRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // *PremiumMyBoosts
return nil
})
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
Slots | []int | — | Which boost slots to assign to this peer. |
Peer | InputPeerClass | yes | The peer to boost. |
Returns
Possible errors
| Code | Type | Description |
|---|---|---|
| 400 | BOOSTS_EMPTY | No boost slots were specified. |
| 400 | PEER_ID_INVALID | The provided peer id is invalid. |
| 400 | SLOTS_EMPTY | The specified slot list is empty. |
References
- Official documentation
- Generated Go reference
- TL definition:
premium.applyBoost#6b7da746