get_privacy()

Client.get_privacy()

Get account privacy rules.

Usable by Users Bots
Parameters:

key (PrivacyKey) – Privacy key.

Returns:

List of PrivacyRule – On success, the list of privacy rules is returned.

Example

from pyrogram import enums
await app.get_privacy(enums.PrivacyKey.PHONE_NUMBER)