channels.getChannelRecommendations
Obtain a list of similarly themed public channels, selected based on similarities in their subscriber bases.
func (c *Client) ChannelsGetChannelRecommendations(ctx context.Context, request *ChannelsGetChannelRecommendationsRequest) (MessagesChatsClass, error)
Calling this method
client.Run(ctx, func(ctx context.Context) error {
api := client.API()
res, err := api.ChannelsGetChannelRecommendations(ctx, &tg.ChannelsGetChannelRecommendationsRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // MessagesChatsClass
return nil
})
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
Channel | InputChannelClass | — | The method will return channels related to the passed channel. If not set, the method will returns channels related to channels the user has joined. |
Returns
Possible errors
| Code | Type | Description |
|---|---|---|
| 400 | CHANNEL_INVALID | The provided channel is invalid. |
| 400 | CHANNEL_PRIVATE | You haven't joined this channel/supergroup. |
| 400 | CHAT_NOT_MODIFIED | No changes were made to chat information because the new information you passed is identical to the current information. |
References
- Official documentation
- Generated Go reference
- TL definition:
channels.getChannelRecommendations#25a71742