tdlib / td

Cross-platform library for building Telegram clients
https://core.telegram.org/tdlib
Boost Software License 1.0
7.11k stars 1.44k forks source link

Chat permissions on TDLib #2535

Closed vincentneo closed 1 year ago

vincentneo commented 1 year ago

I used my Telegram Premium account to disable the ability for people to send voice note and video note messages to me, via the official app's Settings > Privacy and Security > Voice Messages > Set to "Nobody".

On the client that I've made, which is logged in to another number, I was expecting to receive either updateChatPermissions or chatEventPermissionsChanged when the above change happened, but seemingly none was received.

Using the same number on the official client shows the mic icon being grayed out, which suggests that the permission change did take effect.

Am I looking at the wrong update events?

Please advice, thank you!

levlam commented 1 year ago

For users you need to additionally check the flag userFullInfo.has_restricted_voice_and_video_note_messages.

vincentneo commented 1 year ago

Thanks! I will check this out later.