Skip to main content

account.updateNotifySettings

Edits notification settings from a given user/group, from all users/all groups.

func (c *Client) AccountUpdateNotifySettings(ctx context.Context, request *AccountUpdateNotifySettingsRequest) (bool, error)

Calling this method

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

res, err := api.AccountUpdateNotifySettings(ctx, &tg.AccountUpdateNotifySettingsRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // bool
return nil
})

Parameters

NameTypeRequiredDescription
PeerInputNotifyPeerClassyesNotification source
SettingsInputPeerNotifySettingsyesNotification settings

Returns

bool

Possible errors

CodeTypeDescription
400CHANNEL_INVALIDThe provided channel is invalid.
400CHANNEL_PRIVATEYou haven't joined this channel/supergroup.
400MSG_ID_INVALIDInvalid message ID provided.
400PEER_ID_INVALIDThe provided peer id is invalid.
400SETTINGS_INVALIDInvalid settings were provided.

References