payments.getStarsRevenueStats
Get Telegram Star revenue statistics ».
func (c *Client) PaymentsGetStarsRevenueStats(ctx context.Context, request *PaymentsGetStarsRevenueStatsRequest) (*PaymentsStarsRevenueStats, error)
Calling this method
client.Run(ctx, func(ctx context.Context) error {
api := client.API()
res, err := api.PaymentsGetStarsRevenueStats(ctx, &tg.PaymentsGetStarsRevenueStatsRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // *PaymentsStarsRevenueStats
return nil
})
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
Dark | bool | — | Whether to enable dark theme for graph colors |
Ton | bool | — | If set, fetches channel/bot ad revenue statistics in TON. |
Peer | InputPeerClass | yes | Get statistics for the specified bot, channel or ourselves (inputPeerSelf). |
Returns
Possible errors
| Code | Type | Description |
|---|---|---|
| 400 | PEER_ID_INVALID | The provided peer id is invalid. |
References
- Official documentation
- Generated Go reference
- TL definition:
payments.getStarsRevenueStats#d91ffad6